Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[TT-12865] Rename config parameter, update usage, support mux params on legacy #6506

Merged
merged 4 commits into from
Sep 12, 2024

Conversation

titpetric
Copy link
Contributor

@titpetric titpetric commented Sep 12, 2024

PR Type

enhancement


Description

  • Renamed configuration fields EnablePrefixMatching and EnableSuffixMatching to EnablePathPrefixMatching and EnablePathSuffixMatching respectively, across multiple files.
  • Updated comments and documentation to reflect the new naming conventions.
  • Modified test cases to use the updated configuration fields.
  • Refactored middleware and session manager logic to accommodate the new path matching configuration.

Changes walkthrough 📝

Relevant files
Enhancement
config.go
Rename configuration fields for path matching options       

config/config.go

  • Renamed EnablePrefixMatching to EnablePathPrefixMatching.
  • Renamed EnableSuffixMatching to EnablePathSuffixMatching.
  • Updated comments to reflect the new naming conventions.
  • +12/-12 
    api_definition.go
    Update API definition to use new path matching config       

    gateway/api_definition.go

  • Updated variable names to use new path matching configuration fields.
  • +2/-2     
    mw_granular_access.go
    Refactor middleware to use updated path matching config   

    gateway/mw_granular_access.go

  • Updated variable names to use new path matching configuration fields.
  • Refactored pattern preparation using PreparePathRegexp.
  • +3/-9     
    session_manager.go
    Update session manager for new path matching config           

    gateway/session_manager.go

  • Updated variable names to use new path matching configuration fields.
  • +2/-2     
    schema.json
    Update JSON schema for path matching configuration             

    cli/linter/schema.json

    • Renamed JSON schema fields for path matching options.
    +2/-2     
    Tests
    api_definition_test.go
    Update test configuration for path prefix matching             

    gateway/api_definition_test.go

    • Modified test configuration to use EnablePathPrefixMatching.
    +1/-1     
    mw_granular_access_test.go
    Update middleware test for path prefix matching                   

    gateway/mw_granular_access_test.go

    • Modified test configuration to use EnablePathPrefixMatching.
    +1/-1     

    💡 PR-Agent usage:
    Comment /help on the PR to get a list of all available PR-Agent tools and their descriptions

    Copy link
    Contributor

    github-actions bot commented Sep 12, 2024

    API Changes

    --- prev.txt	2024-09-12 07:26:28.458302148 +0000
    +++ current.txt	2024-09-12 07:26:25.238280392 +0000
    @@ -5905,7 +5905,7 @@
     	// Regular expressions and parameterized routes will be left alone regardless of this setting.
     	EnableStrictRoutes bool `json:"enable_strict_routes"`
     
    -	// EnablePrefixMatching changes the URL matching from wildcard mode to prefix mode.
    +	// EnablePathPrefixMatching changes the URL matching from wildcard mode to prefix mode.
     	// For example, `/json` matches `*/json*` by current default behaviour.
     	// If prefix matching is enabled, the match will be performed as a prefix match (`/json*`).
     	//
    @@ -5920,16 +5920,16 @@
     	// - Full listen path and endpoint (`/listen-path/json`)
     	// - Stripped listen path (`/json`) - match.
     	//
    -	// For inputs that start with `/`, a prefix match is ensured by prepending
    -	// the start of string `^` caret.
    +	// For inputs that start with `/`, a prefix match is ensured by
    +	// prepending the start of string `^` caret.
     	//
     	// For all other cases, the pattern remains unmodified.
     	//
    -	// Combine this option with EnableSuffixMatching to achieve strict
    -	// url matching with `/json` being evaluated as `^/json$`.
    -	EnablePrefixMatching bool `json:"enable_prefix_matching"`
    +	// Combine this option with `enable_path_suffix_matching` to achieve
    +	// exact url matching with `/json` being evaluated as `^/json$`.
    +	EnablePathPrefixMatching bool `json:"enable_path_prefix_matching"`
     
    -	// EnableSuffixMatching changes the URL matching to match as a suffix.
    +	// EnablePathSuffixMatching changes the URL matching to match as a suffix.
     	// For example: `/json` is matched as `/json$` against the following paths:
     	//
     	// - Full listen path and versioning URL (`/listen-path/v4/json`)
    @@ -5941,12 +5941,12 @@
     	// - Full listen path and endpoint (`/listen-path/json`)
     	// - Stripped listen path (`/json`) - match.
     	//
    -	// If the input pattern already ends with a `$` (`/json$`) then
    -	// the pattern remains unmodified.
    +	// If the input pattern already ends with a `$` (`/json$`)
    +	// then the pattern remains unmodified.
     	//
    -	// Combine this option with EnablePrefixMatching to achieve strict
    -	// url matching with `/json` being evaluated as `^/json$`.
    -	EnableSuffixMatching bool `json:"enable_suffix_matching"`
    +	// Combine this option with `enable_path_prefix_matching` to achieve
    +	// exact url matching with `/json` being evaluated as `^/json$`.
    +	EnablePathSuffixMatching bool `json:"enable_path_suffix_matching"`
     
     	// Disable TLS verification. Required if you are using self-signed certificates.
     	SSLInsecureSkipVerify bool `json:"ssl_insecure_skip_verify"`

    Copy link
    Contributor

    PR Reviewer Guide 🔍

    ⏱️ Estimated effort to review: 2 🔵🔵⚪⚪⚪
    🧪 PR contains tests
    🔒 No security concerns identified
    ⚡ No key issues to review

    Copy link
    Contributor

    github-actions bot commented Sep 12, 2024

    PR Code Suggestions ✨

    CategorySuggestion                                                                                                                                    Score
    Possible bug
    Add error handling for the regex preparation function to enhance robustness

    Refactor the generateRegex function to handle errors that may arise from the
    PreparePathRegexp function, ensuring robust error handling.

    gateway/api_definition.go [831]

    -pattern = httputil.PreparePathRegexp(stringSpec, isPrefixMatch, isSuffixMatch)
    +pattern, err = httputil.PreparePathRegexp(stringSpec, isPrefixMatch, isSuffixMatch)
    +if err != nil {
    +    return nil, err
    +}
     
    Suggestion importance[1-10]: 9

    Why: Adding error handling for the PreparePathRegexp function is important for robustness, as it ensures that any errors during regex preparation are properly managed, preventing potential runtime issues.

    9
    Check for empty URL paths array to prevent runtime errors

    Add a check to ensure that the urlPaths array is not empty before proceeding with
    URL matching, to avoid runtime errors.

    gateway/mw_granular_access.go [237-238]

     urlPaths := []string{
         m.Spec.StripListenPath(r.URL.Path),
     }
    +if len(urlPaths) == 0 {
    +    return nil, http.StatusBadRequest
    +}
     
    Suggestion importance[1-10]: 8

    Why: Adding a check for an empty urlPaths array can prevent runtime errors, enhancing the stability and reliability of the URL matching process.

    8
    Possible issue
    Ensure new configuration options are mutually exclusive to prevent conflicts

    Ensure that the new configuration options EnablePathPrefixMatching and
    EnablePathSuffixMatching are mutually exclusive to prevent conflicting URL matching
    behaviors.

    config/config.go [433-452]

    +// Add logic to ensure these options are mutually exclusive
     EnablePathPrefixMatching bool `json:"enable_path_prefix_matching"`
     EnablePathSuffixMatching bool `json:"enable_path_suffix_matching"`
     
    Suggestion importance[1-10]: 8

    Why: Ensuring that EnablePathPrefixMatching and EnablePathSuffixMatching are mutually exclusive can prevent conflicting URL matching behaviors, which is crucial for maintaining correct application logic.

    8
    Best practice
    Add a default value for the new configuration option to ensure consistent behavior

    Consider adding a default value for EnablePathPrefixMatching in the struct
    definition to ensure consistent behavior when this configuration is not explicitly
    set by the user.

    config/config.go [433]

    -EnablePathPrefixMatching bool `json:"enable_path_prefix_matching"`
    +EnablePathPrefixMatching bool `json:"enable_path_prefix_matching" default:"false"`
     
    Suggestion importance[1-10]: 7

    Why: Adding a default value for EnablePathPrefixMatching can help ensure consistent behavior when the configuration is not explicitly set, improving code robustness and maintainability.

    7

    @titpetric titpetric requested a review from a team as a code owner September 12, 2024 07:25
    @titpetric titpetric changed the title [TT-12865] Rename config parameter, update usage, support mux params on legacy WIP [TT-12865] Rename config parameter, update usage, support mux params on legacy Sep 12, 2024
    Copy link

    @titpetric titpetric enabled auto-merge (squash) September 12, 2024 07:40
    @titpetric titpetric changed the title WIP [TT-12865] Rename config parameter, update usage, support mux params on legacy [TT-12865] Rename config parameter, update usage, support mux params on legacy Sep 12, 2024
    @titpetric titpetric merged commit 89bcc57 into master Sep 12, 2024
    27 checks passed
    @titpetric titpetric deleted the fix/tt-12865/fix-config-params branch September 12, 2024 07:47
    @titpetric
    Copy link
    Contributor Author

    /release to release-5.3

    Copy link

    tykbot bot commented Sep 12, 2024

    Working on it! Note that it can take a few minutes.

    tykbot bot pushed a commit that referenced this pull request Sep 12, 2024
    …ams on legacy (#6506)
    
    enhancement
    
    ___
    
    - Renamed configuration fields `EnablePrefixMatching` and
    `EnableSuffixMatching` to `EnablePathPrefixMatching` and
    `EnablePathSuffixMatching` respectively, across multiple files.
    - Updated comments and documentation to reflect the new naming
    conventions.
    - Modified test cases to use the updated configuration fields.
    - Refactored middleware and session manager logic to accommodate the new
    path matching configuration.
    
    ___
    
    <table><thead><tr><th></th><th align="left">Relevant
    files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><table>
    <tr>
      <td>
        <details>
    <summary><strong>config.go</strong><dd><code>Rename configuration fields
    for path matching options</code>&nbsp; &nbsp; &nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    config/config.go
    
    <li>Renamed <code>EnablePrefixMatching</code> to
    <code>EnablePathPrefixMatching</code>.<br> <li> Renamed
    <code>EnableSuffixMatching</code> to
    <code>EnablePathSuffixMatching</code>.<br> <li> Updated comments to
    reflect the new naming conventions.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-fe44f09c4d5977b5f5eaea29170b6a0748819c9d02271746a20d81a5f3efca17">+12/-12</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>api_definition.go</strong><dd><code>Update API
    definition to use new path matching config</code>&nbsp; &nbsp; &nbsp;
    &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-0cf80174bbafb36f6d4f4308ebbd971b2833b76a936bad568220aa1a4ba0ee8b">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access.go</strong><dd><code>Refactor
    middleware to use updated path matching config</code>&nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    gateway/mw_granular_access.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br> <li> Refactored pattern preparation using
    <code>PreparePathRegexp</code>.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-618f7d55751d572562a29506a13beba2da969436e974f8b51df7d9708c925436">+3/-9</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>session_manager.go</strong><dd><code>Update session
    manager for new path matching config</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/session_manager.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-e6b40a285464cd86736e970c4c0b320b44c75b18b363d38c200e9a9d36cdabb6">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>schema.json</strong><dd><code>Update JSON schema for
    path matching configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    cli/linter/schema.json
    
    - Renamed JSON schema fields for path matching options.
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-103cec746d3e61d391c5a67c171963f66fea65d651d704d5540e60aa5d574f46">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    </table></td></tr><tr><td><strong>Tests</strong></td><td><table>
    <tr>
      <td>
        <details>
    <summary><strong>api_definition_test.go</strong><dd><code>Update test
    configuration for path prefix matching</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition_test.go
    
    - Modified test configuration to use `EnablePathPrefixMatching`.
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-2394daab6fdc5f8dc234699c80c0548947ee3d68d2e33858258d73a8b5eb6f44">+1/-1</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access_test.go</strong><dd><code>Update
    middleware test for path prefix matching</code>&nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/mw_granular_access_test.go
    
    - Modified test configuration to use `EnablePathPrefixMatching`.
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-8e0d7cfef26688edd7d08334d955039dab5deb3caf860d29eff6d09894eaba20">+1/-1</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    </table></td></tr></tr></tbody></table>
    
    ___
    
    > 💡 **PR-Agent usage**:
    >Comment `/help` on the PR to get a list of all available PR-Agent tools
    and their descriptions
    
    ---------
    
    Co-authored-by: Tit Petric <[email protected]>
    
    (cherry picked from commit 89bcc57)
    Copy link

    tykbot bot commented Sep 12, 2024

    @titpetric Succesfully merged PR

    titpetric added a commit that referenced this pull request Sep 12, 2024
    …age, support mux params on legacy (#6506) (#6507)
    
    ### **User description**
    
    [TT-12865] Rename config parameter, update usage, support mux params on
    legacy (#6506)
    
    ### **PR Type**
    enhancement
    
    
    ___
    
    ### **Description**
    - Renamed configuration fields `EnablePrefixMatching` and
    `EnableSuffixMatching` to `EnablePathPrefixMatching` and
    `EnablePathSuffixMatching` respectively, across multiple files.
    - Updated comments and documentation to reflect the new naming
    conventions.
    - Modified test cases to use the updated configuration fields.
    - Refactored middleware and session manager logic to accommodate the new
    path matching configuration.
    
    
    ___
    
    
    
    ### **Changes walkthrough** 📝
    <table><thead><tr><th></th><th align="left">Relevant
    
    files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><table>
    <tr>
      <td>
        <details>
    <summary><strong>config.go</strong><dd><code>Rename configuration fields
    for path matching options</code>&nbsp; &nbsp; &nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    config/config.go
    
    <li>Renamed <code>EnablePrefixMatching</code> to
    <code>EnablePathPrefixMatching</code>.<br> <li> Renamed
    <code>EnableSuffixMatching</code> to
    <code>EnablePathSuffixMatching</code>.<br> <li> Updated comments to
    reflect the new naming conventions.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-fe44f09c4d5977b5f5eaea29170b6a0748819c9d02271746a20d81a5f3efca17">+12/-12</a>&nbsp;
    </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>api_definition.go</strong><dd><code>Update API
    definition to use new path matching config</code>&nbsp; &nbsp; &nbsp;
    &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-0cf80174bbafb36f6d4f4308ebbd971b2833b76a936bad568220aa1a4ba0ee8b">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access.go</strong><dd><code>Refactor
    middleware to use updated path matching config</code>&nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    gateway/mw_granular_access.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br> <li> Refactored pattern preparation using
    <code>PreparePathRegexp</code>.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-618f7d55751d572562a29506a13beba2da969436e974f8b51df7d9708c925436">+3/-9</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>session_manager.go</strong><dd><code>Update session
    manager for new path matching config</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/session_manager.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-e6b40a285464cd86736e970c4c0b320b44c75b18b363d38c200e9a9d36cdabb6">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>schema.json</strong><dd><code>Update JSON schema for
    path matching configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    cli/linter/schema.json
    
    - Renamed JSON schema fields for path matching options.
    
    
    
    </details>
    
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-103cec746d3e61d391c5a67c171963f66fea65d651d704d5540e60aa5d574f46">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>                    
    </table></td></tr><tr><td><strong>Tests</strong></td><td><table>
    <tr>
      <td>
        <details>
    <summary><strong>api_definition_test.go</strong><dd><code>Update test
    configuration for path prefix matching</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition_test.go
    
    - Modified test configuration to use `EnablePathPrefixMatching`.
    
    
    
    </details>
    
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-2394daab6fdc5f8dc234699c80c0548947ee3d68d2e33858258d73a8b5eb6f44">+1/-1</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access_test.go</strong><dd><code>Update
    middleware test for path prefix matching</code>&nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/mw_granular_access_test.go
    
    - Modified test configuration to use `EnablePathPrefixMatching`.
    
    
    
    </details>
    
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-8e0d7cfef26688edd7d08334d955039dab5deb3caf860d29eff6d09894eaba20">+1/-1</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>                    
    </table></td></tr></tr></tbody></table>
    
    ___
    
    > 💡 **PR-Agent usage**:
    >Comment `/help` on the PR to get a list of all available PR-Agent tools
    and their descriptions
    
    ---------
    
    Co-authored-by: Tit Petric <[email protected]>
    
    [TT-12865]:
    https://tyktech.atlassian.net/browse/TT-12865?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
    
    
    ___
    
    ### **PR Type**
    Enhancement, Tests
    
    
    ___
    
    ### **Description**
    - Introduced new configuration options `EnablePathPrefixMatching` and
    `EnablePathSuffixMatching` to enhance URL path matching capabilities.
    - Refactored URLSpec and related logic to support the new path matching
    configuration.
    - Updated middleware and session management to utilize the new path
    matching options.
    - Added comprehensive tests for the new path matching logic, including
    regression tests for issue 12865.
    - Improved logging and error handling in path matching processes.
    
    
    ___
    
    
    
    ### **Changes walkthrough** 📝
    <table><thead><tr><th></th><th align="left">Relevant
    files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><details><summary>6
    files</summary><table>
    <tr>
      <td>
        <details>
    <summary><strong>config.go</strong><dd><code>Add configuration for path
    prefix and suffix matching</code>&nbsp; &nbsp; &nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    config/config.go
    
    <li>Added new configuration fields <code>EnablePathPrefixMatching</code>
    and <br><code>EnablePathSuffixMatching</code>.<br> <li> Updated comments
    to explain the new path matching configuration.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-fe44f09c4d5977b5f5eaea29170b6a0748819c9d02271746a20d81a5f3efca17">+43/-0</a>&nbsp;
    &nbsp; </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>api_definition.go</strong><dd><code>Refactor URLSpec
    and update path matching logic</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition.go
    
    <li>Refactored URLSpec to use private fields and methods.<br> <li>
    Updated path matching logic to support new configuration.<br> <li>
    Renamed several functions for clarity.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-0cf80174bbafb36f6d4f4308ebbd971b2833b76a936bad568220aa1a4ba0ee8b">+47/-142</a></td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>model_apispec.go</strong><dd><code>Refactor and
    deprecate CheckSpecMatchesStatus</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/model_apispec.go
    
    <li>Moved <code>CheckSpecMatchesStatus</code> to a separate file and
    deprecated it.<br> <li> Added <code>FindSpecMatchesStatus</code> for
    improved status checking.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-80c49b9bdb411a3d5a4706ec3ff138ef44154d0306040c19eba1cb5559f199d6">+75/-0</a>&nbsp;
    &nbsp; </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>model_urlspec.go</strong><dd><code>Add path and method
    matching methods to URLSpec</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/model_urlspec.go
    
    <li>Added new methods to URLSpec for matching paths and methods.<br>
    <li> Deprecated <code>modeSpecificSpec</code> method.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-ed766dd1814a557a1943cd3483c6ef511ad1b8febc7bd59982792d0ab7e23cff">+120/-0</a>&nbsp;
    </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access.go</strong><dd><code>Update
    GranularAccessMiddleware for new path matching</code>&nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/mw_granular_access.go
    
    <li>Updated middleware to use new path matching configuration.<br> <li>
    Improved logging and error handling in path matching.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-618f7d55751d572562a29506a13beba2da969436e974f8b51df7d9708c925436">+74/-20</a>&nbsp;
    </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>mux.go</strong><dd><code>Refactor path regex
    preparation and matching</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    internal/httputil/mux.go
    
    <li>Refactored path regex preparation and matching functions.<br> <li>
    Improved caching and handling of mux-style parameters.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-3d9ee5f5e946d72e6f2ae662ff03ee5253bbdc15203d2e4f6e9f46c13011ebf8">+78/-18</a>&nbsp;
    </td>
    
    </tr>                    
    
    </table></details></td></tr><tr><td><strong>Tests</strong></td><td><details><summary>4
    files</summary><table>
    <tr>
      <td>
        <details>
    <summary><strong>api_definition_test.go</strong><dd><code>Update and add
    test cases for path matching logic</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition_test.go
    
    <li>Updated test cases to reflect changes in path matching logic.<br>
    <li> Added new test cases for path prefix matching.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-2394daab6fdc5f8dc234699c80c0548947ee3d68d2e33858258d73a8b5eb6f44">+12/-12</a>&nbsp;
    </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access_test.go</strong><dd><code>Add tests
    for GranularAccessMiddleware path matching</code>&nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/mw_granular_access_test.go
    
    <li>Added tests for new path matching logic in
    GranularAccessMiddleware.<br> <li> Updated existing tests to use new
    configuration.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-8e0d7cfef26688edd7d08334d955039dab5deb3caf860d29eff6d09894eaba20">+50/-28</a>&nbsp;
    </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>mux_test.go</strong><dd><code>Add tests for path regex
    preparation and matching</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    internal/httputil/mux_test.go
    
    <li>Added tests for new path matching functions.<br> <li> Updated
    existing tests to reflect changes in regex preparation.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-8f7ce1891e221d7adb9e68f2e951f33edfbde2128187abb6e837ac01952d7888">+112/-14</a></td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>issue_12865_test.go</strong><dd><code>Add regression
    tests for issue 12865</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    tests/regression/issue_12865_test.go
    
    <li>Added regression tests for issue 12865.<br> <li> Tested various
    configurations of path prefix and suffix matching.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-1a4f9c47cb4152844d641098b6e7ca8e5e8739eefdec7178f9437750d11db6ec">+171/-0</a>&nbsp;
    </td>
    
    </tr>                    
    </table></details></td></tr><tr><td><strong>Configuration
    changes</strong></td><td><details><summary>2 files</summary><table>
    <tr>
      <td>
        <details>
    <summary><strong>test.yml</strong><dd><code>Update test task
    configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    .taskfiles/test.yml
    
    <li>Updated test task to exclude the first package in the list.<br> <li>
    Added a task to merge coverage reports.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-f1fbe7f7f14888019b8845634ed008e1c43f6e5a5c0b2707336fc7f8e15a36fb">+2/-1</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>schema.json</strong><dd><code>Update schema for new
    path matching configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    cli/linter/schema.json
    
    - Added new schema fields for path prefix and suffix matching.
    
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-103cec746d3e61d391c5a67c171963f66fea65d651d704d5540e60aa5d574f46">+6/-0</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>                    
    </table></details></td></tr></tr></tbody></table>
    
    ___
    
    > 💡 **PR-Agent usage**:
    >Comment `/help` on the PR to get a list of all available PR-Agent tools
    and their descriptions
    
    ---------
    
    Co-authored-by: Tit Petric <[email protected]>
    Co-authored-by: Tit Petric <[email protected]>
    titpetric added a commit that referenced this pull request Sep 12, 2024
    …age, support mux params on legacy (#6506) (#6507)
    
    [TT-12865] Rename config parameter, update usage, support mux params on
    legacy (#6506)
    
    enhancement
    
    ___
    
    - Renamed configuration fields `EnablePrefixMatching` and
    `EnableSuffixMatching` to `EnablePathPrefixMatching` and
    `EnablePathSuffixMatching` respectively, across multiple files.
    - Updated comments and documentation to reflect the new naming
    conventions.
    - Modified test cases to use the updated configuration fields.
    - Refactored middleware and session manager logic to accommodate the new
    path matching configuration.
    
    ___
    
    <table><thead><tr><th></th><th align="left">Relevant
    
    files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><table>
    <tr>
      <td>
        <details>
    <summary><strong>config.go</strong><dd><code>Rename configuration fields
    for path matching options</code>&nbsp; &nbsp; &nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    config/config.go
    
    <li>Renamed <code>EnablePrefixMatching</code> to
    <code>EnablePathPrefixMatching</code>.<br> <li> Renamed
    <code>EnableSuffixMatching</code> to
    <code>EnablePathSuffixMatching</code>.<br> <li> Updated comments to
    reflect the new naming conventions.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-fe44f09c4d5977b5f5eaea29170b6a0748819c9d02271746a20d81a5f3efca17">+12/-12</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>api_definition.go</strong><dd><code>Update API
    definition to use new path matching config</code>&nbsp; &nbsp; &nbsp;
    &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-0cf80174bbafb36f6d4f4308ebbd971b2833b76a936bad568220aa1a4ba0ee8b">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access.go</strong><dd><code>Refactor
    middleware to use updated path matching config</code>&nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    gateway/mw_granular_access.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br> <li> Refactored pattern preparation using
    <code>PreparePathRegexp</code>.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-618f7d55751d572562a29506a13beba2da969436e974f8b51df7d9708c925436">+3/-9</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>session_manager.go</strong><dd><code>Update session
    manager for new path matching config</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/session_manager.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-e6b40a285464cd86736e970c4c0b320b44c75b18b363d38c200e9a9d36cdabb6">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>schema.json</strong><dd><code>Update JSON schema for
    path matching configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    cli/linter/schema.json
    
    - Renamed JSON schema fields for path matching options.
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-103cec746d3e61d391c5a67c171963f66fea65d651d704d5540e60aa5d574f46">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    </table></td></tr><tr><td><strong>Tests</strong></td><td><table>
    <tr>
      <td>
        <details>
    <summary><strong>api_definition_test.go</strong><dd><code>Update test
    configuration for path prefix matching</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition_test.go
    
    - Modified test configuration to use `EnablePathPrefixMatching`.
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-2394daab6fdc5f8dc234699c80c0548947ee3d68d2e33858258d73a8b5eb6f44">+1/-1</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access_test.go</strong><dd><code>Update
    middleware test for path prefix matching</code>&nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/mw_granular_access_test.go
    
    - Modified test configuration to use `EnablePathPrefixMatching`.
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-8e0d7cfef26688edd7d08334d955039dab5deb3caf860d29eff6d09894eaba20">+1/-1</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    </table></td></tr></tr></tbody></table>
    
    ___
    
    > 💡 **PR-Agent usage**:
    >Comment `/help` on the PR to get a list of all available PR-Agent tools
    and their descriptions
    
    ---------
    
    Co-authored-by: Tit Petric <[email protected]>
    
    [TT-12865]:
    https://tyktech.atlassian.net/browse/TT-12865?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
    
    ___
    
    Enhancement, Tests
    
    ___
    
    - Introduced new configuration options `EnablePathPrefixMatching` and
    `EnablePathSuffixMatching` to enhance URL path matching capabilities.
    - Refactored URLSpec and related logic to support the new path matching
    configuration.
    - Updated middleware and session management to utilize the new path
    matching options.
    - Added comprehensive tests for the new path matching logic, including
    regression tests for issue 12865.
    - Improved logging and error handling in path matching processes.
    
    ___
    
    <table><thead><tr><th></th><th align="left">Relevant
    files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><details><summary>6
    files</summary><table>
    <tr>
      <td>
        <details>
    <summary><strong>config.go</strong><dd><code>Add configuration for path
    prefix and suffix matching</code>&nbsp; &nbsp; &nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    config/config.go
    
    <li>Added new configuration fields <code>EnablePathPrefixMatching</code>
    and <br><code>EnablePathSuffixMatching</code>.<br> <li> Updated comments
    to explain the new path matching configuration.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-fe44f09c4d5977b5f5eaea29170b6a0748819c9d02271746a20d81a5f3efca17">+43/-0</a>&nbsp;
    &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>api_definition.go</strong><dd><code>Refactor URLSpec
    and update path matching logic</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition.go
    
    <li>Refactored URLSpec to use private fields and methods.<br> <li>
    Updated path matching logic to support new configuration.<br> <li>
    Renamed several functions for clarity.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-0cf80174bbafb36f6d4f4308ebbd971b2833b76a936bad568220aa1a4ba0ee8b">+47/-142</a></td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>model_apispec.go</strong><dd><code>Refactor and
    deprecate CheckSpecMatchesStatus</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/model_apispec.go
    
    <li>Moved <code>CheckSpecMatchesStatus</code> to a separate file and
    deprecated it.<br> <li> Added <code>FindSpecMatchesStatus</code> for
    improved status checking.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-80c49b9bdb411a3d5a4706ec3ff138ef44154d0306040c19eba1cb5559f199d6">+75/-0</a>&nbsp;
    &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>model_urlspec.go</strong><dd><code>Add path and method
    matching methods to URLSpec</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/model_urlspec.go
    
    <li>Added new methods to URLSpec for matching paths and methods.<br>
    <li> Deprecated <code>modeSpecificSpec</code> method.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-ed766dd1814a557a1943cd3483c6ef511ad1b8febc7bd59982792d0ab7e23cff">+120/-0</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access.go</strong><dd><code>Update
    GranularAccessMiddleware for new path matching</code>&nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/mw_granular_access.go
    
    <li>Updated middleware to use new path matching configuration.<br> <li>
    Improved logging and error handling in path matching.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-618f7d55751d572562a29506a13beba2da969436e974f8b51df7d9708c925436">+74/-20</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mux.go</strong><dd><code>Refactor path regex
    preparation and matching</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    internal/httputil/mux.go
    
    <li>Refactored path regex preparation and matching functions.<br> <li>
    Improved caching and handling of mux-style parameters.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-3d9ee5f5e946d72e6f2ae662ff03ee5253bbdc15203d2e4f6e9f46c13011ebf8">+78/-18</a>&nbsp;
    </td>
    
    </tr>
    
    </table></details></td></tr><tr><td><strong>Tests</strong></td><td><details><summary>4
    files</summary><table>
    <tr>
      <td>
        <details>
    <summary><strong>api_definition_test.go</strong><dd><code>Update and add
    test cases for path matching logic</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition_test.go
    
    <li>Updated test cases to reflect changes in path matching logic.<br>
    <li> Added new test cases for path prefix matching.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-2394daab6fdc5f8dc234699c80c0548947ee3d68d2e33858258d73a8b5eb6f44">+12/-12</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access_test.go</strong><dd><code>Add tests
    for GranularAccessMiddleware path matching</code>&nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/mw_granular_access_test.go
    
    <li>Added tests for new path matching logic in
    GranularAccessMiddleware.<br> <li> Updated existing tests to use new
    configuration.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-8e0d7cfef26688edd7d08334d955039dab5deb3caf860d29eff6d09894eaba20">+50/-28</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mux_test.go</strong><dd><code>Add tests for path regex
    preparation and matching</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    internal/httputil/mux_test.go
    
    <li>Added tests for new path matching functions.<br> <li> Updated
    existing tests to reflect changes in regex preparation.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-8f7ce1891e221d7adb9e68f2e951f33edfbde2128187abb6e837ac01952d7888">+112/-14</a></td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>issue_12865_test.go</strong><dd><code>Add regression
    tests for issue 12865</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    tests/regression/issue_12865_test.go
    
    <li>Added regression tests for issue 12865.<br> <li> Tested various
    configurations of path prefix and suffix matching.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-1a4f9c47cb4152844d641098b6e7ca8e5e8739eefdec7178f9437750d11db6ec">+171/-0</a>&nbsp;
    </td>
    
    </tr>
    </table></details></td></tr><tr><td><strong>Configuration
    changes</strong></td><td><details><summary>2 files</summary><table>
    <tr>
      <td>
        <details>
    <summary><strong>test.yml</strong><dd><code>Update test task
    configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    .taskfiles/test.yml
    
    <li>Updated test task to exclude the first package in the list.<br> <li>
    Added a task to merge coverage reports.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-f1fbe7f7f14888019b8845634ed008e1c43f6e5a5c0b2707336fc7f8e15a36fb">+2/-1</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>schema.json</strong><dd><code>Update schema for new
    path matching configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    cli/linter/schema.json
    
    - Added new schema fields for path prefix and suffix matching.
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-103cec746d3e61d391c5a67c171963f66fea65d651d704d5540e60aa5d574f46">+6/-0</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    </table></details></td></tr></tr></tbody></table>
    
    ___
    
    > 💡 **PR-Agent usage**:
    >Comment `/help` on the PR to get a list of all available PR-Agent tools
    and their descriptions
    
    ---------
    
    Co-authored-by: Tit Petric <[email protected]>
    Co-authored-by: Tit Petric <[email protected]>
    titpetric added a commit that referenced this pull request Sep 12, 2024
    …age, support mux params on legacy (#6506) (#6507)
    
    [TT-12865] Rename config parameter, update usage, support mux params on
    legacy (#6506)
    
    enhancement
    
    ___
    
    - Renamed configuration fields `EnablePrefixMatching` and
    `EnableSuffixMatching` to `EnablePathPrefixMatching` and
    `EnablePathSuffixMatching` respectively, across multiple files.
    - Updated comments and documentation to reflect the new naming
    conventions.
    - Modified test cases to use the updated configuration fields.
    - Refactored middleware and session manager logic to accommodate the new
    path matching configuration.
    
    ___
    
    <table><thead><tr><th></th><th align="left">Relevant
    
    files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><table>
    <tr>
      <td>
        <details>
    <summary><strong>config.go</strong><dd><code>Rename configuration fields
    for path matching options</code>&nbsp; &nbsp; &nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    config/config.go
    
    <li>Renamed <code>EnablePrefixMatching</code> to
    <code>EnablePathPrefixMatching</code>.<br> <li> Renamed
    <code>EnableSuffixMatching</code> to
    <code>EnablePathSuffixMatching</code>.<br> <li> Updated comments to
    reflect the new naming conventions.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-fe44f09c4d5977b5f5eaea29170b6a0748819c9d02271746a20d81a5f3efca17">+12/-12</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>api_definition.go</strong><dd><code>Update API
    definition to use new path matching config</code>&nbsp; &nbsp; &nbsp;
    &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-0cf80174bbafb36f6d4f4308ebbd971b2833b76a936bad568220aa1a4ba0ee8b">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access.go</strong><dd><code>Refactor
    middleware to use updated path matching config</code>&nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    gateway/mw_granular_access.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br> <li> Refactored pattern preparation using
    <code>PreparePathRegexp</code>.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-618f7d55751d572562a29506a13beba2da969436e974f8b51df7d9708c925436">+3/-9</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>session_manager.go</strong><dd><code>Update session
    manager for new path matching config</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/session_manager.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-e6b40a285464cd86736e970c4c0b320b44c75b18b363d38c200e9a9d36cdabb6">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>schema.json</strong><dd><code>Update JSON schema for
    path matching configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    cli/linter/schema.json
    
    - Renamed JSON schema fields for path matching options.
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-103cec746d3e61d391c5a67c171963f66fea65d651d704d5540e60aa5d574f46">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    </table></td></tr><tr><td><strong>Tests</strong></td><td><table>
    <tr>
      <td>
        <details>
    <summary><strong>api_definition_test.go</strong><dd><code>Update test
    configuration for path prefix matching</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition_test.go
    
    - Modified test configuration to use `EnablePathPrefixMatching`.
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-2394daab6fdc5f8dc234699c80c0548947ee3d68d2e33858258d73a8b5eb6f44">+1/-1</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access_test.go</strong><dd><code>Update
    middleware test for path prefix matching</code>&nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/mw_granular_access_test.go
    
    - Modified test configuration to use `EnablePathPrefixMatching`.
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-8e0d7cfef26688edd7d08334d955039dab5deb3caf860d29eff6d09894eaba20">+1/-1</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    </table></td></tr></tr></tbody></table>
    
    ___
    
    > 💡 **PR-Agent usage**:
    >Comment `/help` on the PR to get a list of all available PR-Agent tools
    and their descriptions
    
    ---------
    
    Co-authored-by: Tit Petric <[email protected]>
    
    [TT-12865]:
    https://tyktech.atlassian.net/browse/TT-12865?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
    
    ___
    
    Enhancement, Tests
    
    ___
    
    - Introduced new configuration options `EnablePathPrefixMatching` and
    `EnablePathSuffixMatching` to enhance URL path matching capabilities.
    - Refactored URLSpec and related logic to support the new path matching
    configuration.
    - Updated middleware and session management to utilize the new path
    matching options.
    - Added comprehensive tests for the new path matching logic, including
    regression tests for issue 12865.
    - Improved logging and error handling in path matching processes.
    
    ___
    
    <table><thead><tr><th></th><th align="left">Relevant
    files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><details><summary>6
    files</summary><table>
    <tr>
      <td>
        <details>
    <summary><strong>config.go</strong><dd><code>Add configuration for path
    prefix and suffix matching</code>&nbsp; &nbsp; &nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    config/config.go
    
    <li>Added new configuration fields <code>EnablePathPrefixMatching</code>
    and <br><code>EnablePathSuffixMatching</code>.<br> <li> Updated comments
    to explain the new path matching configuration.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-fe44f09c4d5977b5f5eaea29170b6a0748819c9d02271746a20d81a5f3efca17">+43/-0</a>&nbsp;
    &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>api_definition.go</strong><dd><code>Refactor URLSpec
    and update path matching logic</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition.go
    
    <li>Refactored URLSpec to use private fields and methods.<br> <li>
    Updated path matching logic to support new configuration.<br> <li>
    Renamed several functions for clarity.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-0cf80174bbafb36f6d4f4308ebbd971b2833b76a936bad568220aa1a4ba0ee8b">+47/-142</a></td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>model_apispec.go</strong><dd><code>Refactor and
    deprecate CheckSpecMatchesStatus</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/model_apispec.go
    
    <li>Moved <code>CheckSpecMatchesStatus</code> to a separate file and
    deprecated it.<br> <li> Added <code>FindSpecMatchesStatus</code> for
    improved status checking.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-80c49b9bdb411a3d5a4706ec3ff138ef44154d0306040c19eba1cb5559f199d6">+75/-0</a>&nbsp;
    &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>model_urlspec.go</strong><dd><code>Add path and method
    matching methods to URLSpec</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/model_urlspec.go
    
    <li>Added new methods to URLSpec for matching paths and methods.<br>
    <li> Deprecated <code>modeSpecificSpec</code> method.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-ed766dd1814a557a1943cd3483c6ef511ad1b8febc7bd59982792d0ab7e23cff">+120/-0</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access.go</strong><dd><code>Update
    GranularAccessMiddleware for new path matching</code>&nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/mw_granular_access.go
    
    <li>Updated middleware to use new path matching configuration.<br> <li>
    Improved logging and error handling in path matching.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-618f7d55751d572562a29506a13beba2da969436e974f8b51df7d9708c925436">+74/-20</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mux.go</strong><dd><code>Refactor path regex
    preparation and matching</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    internal/httputil/mux.go
    
    <li>Refactored path regex preparation and matching functions.<br> <li>
    Improved caching and handling of mux-style parameters.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-3d9ee5f5e946d72e6f2ae662ff03ee5253bbdc15203d2e4f6e9f46c13011ebf8">+78/-18</a>&nbsp;
    </td>
    
    </tr>
    
    </table></details></td></tr><tr><td><strong>Tests</strong></td><td><details><summary>4
    files</summary><table>
    <tr>
      <td>
        <details>
    <summary><strong>api_definition_test.go</strong><dd><code>Update and add
    test cases for path matching logic</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition_test.go
    
    <li>Updated test cases to reflect changes in path matching logic.<br>
    <li> Added new test cases for path prefix matching.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-2394daab6fdc5f8dc234699c80c0548947ee3d68d2e33858258d73a8b5eb6f44">+12/-12</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access_test.go</strong><dd><code>Add tests
    for GranularAccessMiddleware path matching</code>&nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/mw_granular_access_test.go
    
    <li>Added tests for new path matching logic in
    GranularAccessMiddleware.<br> <li> Updated existing tests to use new
    configuration.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-8e0d7cfef26688edd7d08334d955039dab5deb3caf860d29eff6d09894eaba20">+50/-28</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mux_test.go</strong><dd><code>Add tests for path regex
    preparation and matching</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    internal/httputil/mux_test.go
    
    <li>Added tests for new path matching functions.<br> <li> Updated
    existing tests to reflect changes in regex preparation.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-8f7ce1891e221d7adb9e68f2e951f33edfbde2128187abb6e837ac01952d7888">+112/-14</a></td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>issue_12865_test.go</strong><dd><code>Add regression
    tests for issue 12865</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    tests/regression/issue_12865_test.go
    
    <li>Added regression tests for issue 12865.<br> <li> Tested various
    configurations of path prefix and suffix matching.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-1a4f9c47cb4152844d641098b6e7ca8e5e8739eefdec7178f9437750d11db6ec">+171/-0</a>&nbsp;
    </td>
    
    </tr>
    </table></details></td></tr><tr><td><strong>Configuration
    changes</strong></td><td><details><summary>2 files</summary><table>
    <tr>
      <td>
        <details>
    <summary><strong>test.yml</strong><dd><code>Update test task
    configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    .taskfiles/test.yml
    
    <li>Updated test task to exclude the first package in the list.<br> <li>
    Added a task to merge coverage reports.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-f1fbe7f7f14888019b8845634ed008e1c43f6e5a5c0b2707336fc7f8e15a36fb">+2/-1</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>schema.json</strong><dd><code>Update schema for new
    path matching configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    cli/linter/schema.json
    
    - Added new schema fields for path prefix and suffix matching.
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-103cec746d3e61d391c5a67c171963f66fea65d651d704d5540e60aa5d574f46">+6/-0</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    </table></details></td></tr></tr></tbody></table>
    
    ___
    
    > 💡 **PR-Agent usage**:
    >Comment `/help` on the PR to get a list of all available PR-Agent tools
    and their descriptions
    
    ---------
    
    Co-authored-by: Tit Petric <[email protected]>
    Co-authored-by: Tit Petric <[email protected]>
    buger added a commit that referenced this pull request Sep 13, 2024
    …pport mux params on legacy (#6510)
    
    ### **User description**
    [TT-12865] Rename config parameter, update usage, support mux params on
    legacy (#6506)
    
    enhancement
    
    ___
    
    - Renamed configuration fields `EnablePrefixMatching` and
    `EnableSuffixMatching` to `EnablePathPrefixMatching` and
    `EnablePathSuffixMatching` respectively, across multiple files.
    - Updated comments and documentation to reflect the new naming
    conventions.
    - Modified test cases to use the updated configuration fields.
    - Refactored middleware and session manager logic to accommodate the new
    path matching configuration.
    
    ___
    
    <table><thead><tr><th></th><th align="left">Relevant
    
    
    files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><table>
    <tr>
      <td>
        <details>
    <summary><strong>config.go</strong><dd><code>Rename configuration fields
    for path matching options</code>&nbsp; &nbsp; &nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    config/config.go
    
    <li>Renamed <code>EnablePrefixMatching</code> to
    <code>EnablePathPrefixMatching</code>.<br> <li> Renamed
    <code>EnableSuffixMatching</code> to
    <code>EnablePathSuffixMatching</code>.<br> <li> Updated comments to
    reflect the new naming conventions.<br>
    
    </details>
    
      </td>
    <td><a
    
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-fe44f09c4d5977b5f5eaea29170b6a0748819c9d02271746a20d81a5f3efca17">+12/-12</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>api_definition.go</strong><dd><code>Update API
    definition to use new path matching config</code>&nbsp; &nbsp; &nbsp;
    &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br>
    
    </details>
    
      </td>
    <td><a
    
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-0cf80174bbafb36f6d4f4308ebbd971b2833b76a936bad568220aa1a4ba0ee8b">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access.go</strong><dd><code>Refactor
    middleware to use updated path matching config</code>&nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    gateway/mw_granular_access.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br> <li> Refactored pattern preparation using
    <code>PreparePathRegexp</code>.<br>
    
    </details>
    
      </td>
    <td><a
    
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-618f7d55751d572562a29506a13beba2da969436e974f8b51df7d9708c925436">+3/-9</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>session_manager.go</strong><dd><code>Update session
    manager for new path matching config</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/session_manager.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br>
    
    </details>
    
      </td>
    <td><a
    
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-e6b40a285464cd86736e970c4c0b320b44c75b18b363d38c200e9a9d36cdabb6">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>schema.json</strong><dd><code>Update JSON schema for
    path matching configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    cli/linter/schema.json
    
    - Renamed JSON schema fields for path matching options.
    
    </details>
    
      </td> <td><a
    
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-103cec746d3e61d391c5a67c171963f66fea65d651d704d5540e60aa5d574f46">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    </table></td></tr><tr><td><strong>Tests</strong></td><td><table> <tr>
      <td>
        <details>
    <summary><strong>api_definition_test.go</strong><dd><code>Update test
    configuration for path prefix matching</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition_test.go
    
    - Modified test configuration to use `EnablePathPrefixMatching`.
    
    </details>
    
      </td> <td><a
    
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-2394daab6fdc5f8dc234699c80c0548947ee3d68d2e33858258d73a8b5eb6f44">+1/-1</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access_test.go</strong><dd><code>Update
    middleware test for path prefix matching</code>&nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr>
    
    gateway/mw_granular_access_test.go
    
    - Modified test configuration to use `EnablePathPrefixMatching`.
    
    </details>
    
      </td> <td><a
    
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-8e0d7cfef26688edd7d08334d955039dab5deb3caf860d29eff6d09894eaba20">+1/-1</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    </table></td></tr></tr></tbody></table>
    
    ___
    
    > 💡 **PR-Agent usage**:
    >Comment `/help` on the PR to get a list of all available PR-Agent tools
    and their descriptions
    
    ---------
    
    
    
    [TT-12865]:
    
    https://tyktech.atlassian.net/browse/TT-12865?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
    
    ___
    
    Enhancement, Tests
    
    ___
    
    - Introduced new configuration options `EnablePathPrefixMatching` and
    `EnablePathSuffixMatching` to enhance URL path matching capabilities.
    - Refactored URLSpec and related logic to support the new path matching
    configuration.
    - Updated middleware and session management to utilize the new path
    matching options.
    - Added comprehensive tests for the new path matching logic, including
    regression tests for issue 12865.
    - Improved logging and error handling in path matching processes.
    
    ___
    
    <table><thead><tr><th></th><th align="left">Relevant
    files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><details><summary>6
    files</summary><table>
    <tr>
      <td>
        <details>
    <summary><strong>config.go</strong><dd><code>Add configuration for path
    prefix and suffix matching</code>&nbsp; &nbsp; &nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    config/config.go
    
    <li>Added new configuration fields <code>EnablePathPrefixMatching</code>
    and <br><code>EnablePathSuffixMatching</code>.<br> <li> Updated comments
    to explain the new path matching configuration.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-fe44f09c4d5977b5f5eaea29170b6a0748819c9d02271746a20d81a5f3efca17">+43/-0</a>&nbsp;
    &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>api_definition.go</strong><dd><code>Refactor URLSpec
    and update path matching logic</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr>
    
    gateway/api_definition.go
    
    <li>Refactored URLSpec to use private fields and methods.<br> <li>
    Updated path matching logic to support new configuration.<br> <li>
    Renamed several functions for clarity.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-0cf80174bbafb36f6d4f4308ebbd971b2833b76a936bad568220aa1a4ba0ee8b">+47/-142</a></td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>model_apispec.go</strong><dd><code>Refactor and
    deprecate CheckSpecMatchesStatus</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/model_apispec.go
    
    <li>Moved <code>CheckSpecMatchesStatus</code> to a separate file and
    deprecated it.<br> <li> Added <code>FindSpecMatchesStatus</code> for
    improved status checking.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-80c49b9bdb411a3d5a4706ec3ff138ef44154d0306040c19eba1cb5559f199d6">+75/-0</a>&nbsp;
    &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>model_urlspec.go</strong><dd><code>Add path and method
    matching methods to URLSpec</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr>
    
    gateway/model_urlspec.go
    
    <li>Added new methods to URLSpec for matching paths and methods.<br>
    <li> Deprecated <code>modeSpecificSpec</code> method.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-ed766dd1814a557a1943cd3483c6ef511ad1b8febc7bd59982792d0ab7e23cff">+120/-0</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access.go</strong><dd><code>Update
    GranularAccessMiddleware for new path matching</code>&nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/mw_granular_access.go
    
    <li>Updated middleware to use new path matching configuration.<br> <li>
    Improved logging and error handling in path matching.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-618f7d55751d572562a29506a13beba2da969436e974f8b51df7d9708c925436">+74/-20</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mux.go</strong><dd><code>Refactor path regex
    preparation and matching</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr>
    
    internal/httputil/mux.go
    
    <li>Refactored path regex preparation and matching functions.<br> <li>
    Improved caching and handling of mux-style parameters.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-3d9ee5f5e946d72e6f2ae662ff03ee5253bbdc15203d2e4f6e9f46c13011ebf8">+78/-18</a>&nbsp;
    </td>
    
    </tr>
    
    
    </table></details></td></tr><tr><td><strong>Tests</strong></td><td><details><summary>4
    files</summary><table>
    <tr>
      <td>
        <details>
    <summary><strong>api_definition_test.go</strong><dd><code>Update and add
    test cases for path matching logic</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition_test.go
    
    <li>Updated test cases to reflect changes in path matching logic.<br>
    <li> Added new test cases for path prefix matching.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-2394daab6fdc5f8dc234699c80c0548947ee3d68d2e33858258d73a8b5eb6f44">+12/-12</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access_test.go</strong><dd><code>Add tests
    for GranularAccessMiddleware path matching</code>&nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/mw_granular_access_test.go
    
    <li>Added tests for new path matching logic in
    GranularAccessMiddleware.<br> <li> Updated existing tests to use new
    configuration.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-8e0d7cfef26688edd7d08334d955039dab5deb3caf860d29eff6d09894eaba20">+50/-28</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mux_test.go</strong><dd><code>Add tests for path regex
    preparation and matching</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    internal/httputil/mux_test.go
    
    <li>Added tests for new path matching functions.<br> <li> Updated
    existing tests to reflect changes in regex preparation.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-8f7ce1891e221d7adb9e68f2e951f33edfbde2128187abb6e837ac01952d7888">+112/-14</a></td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>issue_12865_test.go</strong><dd><code>Add regression
    tests for issue 12865</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr>
    
    tests/regression/issue_12865_test.go
    
    <li>Added regression tests for issue 12865.<br> <li> Tested various
    configurations of path prefix and suffix matching.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-1a4f9c47cb4152844d641098b6e7ca8e5e8739eefdec7178f9437750d11db6ec">+171/-0</a>&nbsp;
    </td>
    
    </tr>
    </table></details></td></tr><tr><td><strong>Configuration
    changes</strong></td><td><details><summary>2 files</summary><table> <tr>
      <td>
        <details>
    <summary><strong>test.yml</strong><dd><code>Update test task
    configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    .taskfiles/test.yml
    
    <li>Updated test task to exclude the first package in the list.<br> <li>
    Added a task to merge coverage reports.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-f1fbe7f7f14888019b8845634ed008e1c43f6e5a5c0b2707336fc7f8e15a36fb">+2/-1</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>schema.json</strong><dd><code>Update schema for new
    path matching configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    cli/linter/schema.json
    
    - Added new schema fields for path prefix and suffix matching.
    
    </details>
    
      </td> <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-103cec746d3e61d391c5a67c171963f66fea65d651d704d5540e60aa5d574f46">+6/-0</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    </table></details></td></tr></tr></tbody></table>
    
    ___
    
    > 💡 **PR-Agent usage**:
    >Comment `/help` on the PR to get a list of all available PR-Agent tools
    and their descriptions
    
    ---------
    
    <!-- Provide a general summary of your changes in the Title above -->
    
    ## Description
    
    <!-- Describe your changes in detail -->
    
    ## Related Issue
    
    <!-- This project only accepts pull requests related to open issues. -->
    <!-- If suggesting a new feature or change, please discuss it in an
    issue first. -->
    <!-- If fixing a bug, there should be an issue describing it with steps
    to reproduce. -->
    <!-- OSS: Please link to the issue here. Tyk: please create/link the
    JIRA ticket. -->
    
    ## Motivation and Context
    
    <!-- Why is this change required? What problem does it solve? -->
    
    ## 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. -->
    
    ## Screenshots (if appropriate)
    
    ## Types of changes
    
    <!-- What types of changes does your code introduce? Put an `x` in all
    the boxes that apply: -->
    
    - [ ] Bug fix (non-breaking change which fixes an issue)
    - [ ] New feature (non-breaking change which adds functionality)
    - [ ] Breaking change (fix or feature that would cause existing
    functionality to change)
    - [ ] 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. -->
    
    - [ ] I ensured that the documentation is up to date
    - [ ] I explained why this PR updates go.mod in detail with reasoning
    why it's required
    - [ ] I would like a code coverage CI quality gate exception and have
    explained why
    
    
    [TT-12865]:
    https://tyktech.atlassian.net/browse/TT-12865?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
    [TT-12865]:
    https://tyktech.atlassian.net/browse/TT-12865?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
    
    
    ___
    
    ### **PR Type**
    Enhancement, Tests
    
    
    ___
    
    ### **Description**
    - Introduced new configuration fields `EnablePathPrefixMatching` and
    `EnablePathSuffixMatching` to enhance URL path matching capabilities.
    - Refactored URLSpec and related logic to support the new path matching
    configurations, improving error handling and logging.
    - Updated and added new test cases to cover the new path matching
    options, ensuring comprehensive test coverage.
    - Implemented utility functions for handling path regex preparation and
    matching, with caching for improved performance.
    - Added regression tests for issue 12865, verifying the correct behavior
    of the new path matching configurations.
    
    
    ___
    
    
    
    ### **Changes walkthrough** 📝
    <table><thead><tr><th></th><th align="left">Relevant
    files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><details><summary>5
    files</summary><table>
    <tr>
      <td>
        <details>
    <summary><strong>config.go</strong><dd><code>Add new configuration
    fields for path matching</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    config/config.go
    
    <li>Introduced new configuration fields
    <code>EnablePathPrefixMatching</code> and
    <br><code>EnablePathSuffixMatching</code>.<br> <li> Added detailed
    comments explaining the new path matching <br>configurations.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6510/files#diff-fe44f09c4d5977b5f5eaea29170b6a0748819c9d02271746a20d81a5f3efca17">+43/-0</a>&nbsp;
    &nbsp; </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>api_definition.go</strong><dd><code>Refactor URLSpec
    and enhance path matching logic</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition.go
    
    <li>Refactored URLSpec to use a private field for regex.<br> <li> Added
    logic to handle path prefix and suffix matching.<br> <li> Improved error
    logging for regex compilation.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6510/files#diff-0cf80174bbafb36f6d4f4308ebbd971b2833b76a936bad568220aa1a4ba0ee8b">+55/-166</a></td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access.go</strong><dd><code>Enhance
    GranularAccessMiddleware with path matching
    options</code></dd></summary>
    <hr>
    
    gateway/mw_granular_access.go
    
    <li>Enhanced GranularAccessMiddleware to support new path matching
    <br>options.<br> <li> Improved logging for access checks.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6510/files#diff-618f7d55751d572562a29506a13beba2da969436e974f8b51df7d9708c925436">+79/-12</a>&nbsp;
    </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>mux.go</strong><dd><code>Add utility functions for path
    regex handling</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    internal/httputil/mux.go
    
    <li>Introduced utility functions for path regex preparation and
    matching.<br> <li> Implemented caching for path regex patterns.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6510/files#diff-3d9ee5f5e946d72e6f2ae662ff03ee5253bbdc15203d2e4f6e9f46c13011ebf8">+139/-0</a>&nbsp;
    </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>strings.go</strong><dd><code>Implement concurrency-safe
    string map</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    internal/maps/strings.go
    
    <li>Introduced a concurrency-safe map for string storage.<br> <li>
    Provided methods for setting and getting values.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6510/files#diff-5fa5e244ede81be68269555e950af79079de58236fe9c0e67e6f01a602d04dca">+34/-0</a>&nbsp;
    &nbsp; </td>
    
    </tr>                    
    
    </table></details></td></tr><tr><td><strong>Tests</strong></td><td><details><summary>5
    files</summary><table>
    <tr>
      <td>
        <details>
    <summary><strong>api_definition_test.go</strong><dd><code>Update and add
    tests for path matching configurations</code>&nbsp; &nbsp; &nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    gateway/api_definition_test.go
    
    <li>Updated test cases to reflect new path matching configurations.<br>
    <li> Added new tests for prefix and suffix matching.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6510/files#diff-2394daab6fdc5f8dc234699c80c0548947ee3d68d2e33858258d73a8b5eb6f44">+16/-33</a>&nbsp;
    </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access_test.go</strong><dd><code>Add tests
    for GranularAccessMiddleware path matching</code>&nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/mw_granular_access_test.go
    
    <li>Added tests for GranularAccessMiddleware with new path matching
    <br>configurations.<br> <li> Ensured coverage for both prefix and suffix
    matching scenarios.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6510/files#diff-8e0d7cfef26688edd7d08334d955039dab5deb3caf860d29eff6d09894eaba20">+50/-24</a>&nbsp;
    </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>mux_test.go</strong><dd><code>Add tests for path regex
    utilities</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    internal/httputil/mux_test.go
    
    <li>Added tests for path regex preparation and matching utilities.<br>
    <li> Verified caching behavior for regex patterns.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6510/files#diff-8f7ce1891e221d7adb9e68f2e951f33edfbde2128187abb6e837ac01952d7888">+162/-0</a>&nbsp;
    </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>issue_12865_test.go</strong><dd><code>Add regression
    tests for issue 12865</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    tests/regression/issue_12865_test.go
    
    <li>Added regression tests for issue 12865.<br> <li> Tested various path
    matching configurations.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6510/files#diff-1a4f9c47cb4152844d641098b6e7ca8e5e8739eefdec7178f9437750d11db6ec">+171/-0</a>&nbsp;
    </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>regression_test.go</strong><dd><code>Refactor and test
    API spec loading utilities</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    tests/regression/regression_test.go
    
    <li>Refactored utility functions for loading API specs.<br> <li> Added
    test for loading API specs with environment variable
    <br>replacement.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6510/files#diff-24d0ac1f4eb4bb6e33d0db26aca8ef96aef2b67fd2730fcde6e952ce3d894696">+23/-3</a>&nbsp;
    &nbsp; </td>
    
    </tr>                    
    </table></details></td></tr></tr></tbody></table>
    
    ___
    
    > 💡 **PR-Agent usage**:
    >Comment `/help` on the PR to get a list of all available PR-Agent tools
    and their descriptions
    
    ---------
    
    Co-authored-by: Leonid Bugaev <[email protected]>
    Co-authored-by: Tit Petric <[email protected]>
    jeffy-mathew pushed a commit that referenced this pull request Sep 13, 2024
    …on legacy (#6506)
    
    enhancement
    
    ___
    
    - Renamed configuration fields `EnablePrefixMatching` and
    `EnableSuffixMatching` to `EnablePathPrefixMatching` and
    `EnablePathSuffixMatching` respectively, across multiple files.
    - Updated comments and documentation to reflect the new naming
    conventions.
    - Modified test cases to use the updated configuration fields.
    - Refactored middleware and session manager logic to accommodate the new
    path matching configuration.
    
    ___
    
    <table><thead><tr><th></th><th align="left">Relevant
    files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><table>
    <tr>
      <td>
        <details>
    <summary><strong>config.go</strong><dd><code>Rename configuration fields
    for path matching options</code>&nbsp; &nbsp; &nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    config/config.go
    
    <li>Renamed <code>EnablePrefixMatching</code> to
    <code>EnablePathPrefixMatching</code>.<br> <li> Renamed
    <code>EnableSuffixMatching</code> to
    <code>EnablePathSuffixMatching</code>.<br> <li> Updated comments to
    reflect the new naming conventions.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-fe44f09c4d5977b5f5eaea29170b6a0748819c9d02271746a20d81a5f3efca17">+12/-12</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>api_definition.go</strong><dd><code>Update API
    definition to use new path matching config</code>&nbsp; &nbsp; &nbsp;
    &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-0cf80174bbafb36f6d4f4308ebbd971b2833b76a936bad568220aa1a4ba0ee8b">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access.go</strong><dd><code>Refactor
    middleware to use updated path matching config</code>&nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    gateway/mw_granular_access.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br> <li> Refactored pattern preparation using
    <code>PreparePathRegexp</code>.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-618f7d55751d572562a29506a13beba2da969436e974f8b51df7d9708c925436">+3/-9</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>session_manager.go</strong><dd><code>Update session
    manager for new path matching config</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/session_manager.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-e6b40a285464cd86736e970c4c0b320b44c75b18b363d38c200e9a9d36cdabb6">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>schema.json</strong><dd><code>Update JSON schema for
    path matching configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    cli/linter/schema.json
    
    - Renamed JSON schema fields for path matching options.
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-103cec746d3e61d391c5a67c171963f66fea65d651d704d5540e60aa5d574f46">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    </table></td></tr><tr><td><strong>Tests</strong></td><td><table>
    <tr>
      <td>
        <details>
    <summary><strong>api_definition_test.go</strong><dd><code>Update test
    configuration for path prefix matching</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition_test.go
    
    - Modified test configuration to use `EnablePathPrefixMatching`.
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-2394daab6fdc5f8dc234699c80c0548947ee3d68d2e33858258d73a8b5eb6f44">+1/-1</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access_test.go</strong><dd><code>Update
    middleware test for path prefix matching</code>&nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/mw_granular_access_test.go
    
    - Modified test configuration to use `EnablePathPrefixMatching`.
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-8e0d7cfef26688edd7d08334d955039dab5deb3caf860d29eff6d09894eaba20">+1/-1</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    </table></td></tr></tr></tbody></table>
    
    ___
    
    > 💡 **PR-Agent usage**:
    >Comment `/help` on the PR to get a list of all available PR-Agent tools
    and their descriptions
    
    ---------
    
    Co-authored-by: Tit Petric <[email protected]>
    jeffy-mathew pushed a commit that referenced this pull request Sep 13, 2024
    …on legacy (#6506)
    
    enhancement
    
    ___
    
    - Renamed configuration fields `EnablePrefixMatching` and
    `EnableSuffixMatching` to `EnablePathPrefixMatching` and
    `EnablePathSuffixMatching` respectively, across multiple files.
    - Updated comments and documentation to reflect the new naming
    conventions.
    - Modified test cases to use the updated configuration fields.
    - Refactored middleware and session manager logic to accommodate the new
    path matching configuration.
    
    ___
    
    <table><thead><tr><th></th><th align="left">Relevant
    files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><table>
    <tr>
      <td>
        <details>
    <summary><strong>config.go</strong><dd><code>Rename configuration fields
    for path matching options</code>&nbsp; &nbsp; &nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    config/config.go
    
    <li>Renamed <code>EnablePrefixMatching</code> to
    <code>EnablePathPrefixMatching</code>.<br> <li> Renamed
    <code>EnableSuffixMatching</code> to
    <code>EnablePathSuffixMatching</code>.<br> <li> Updated comments to
    reflect the new naming conventions.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-fe44f09c4d5977b5f5eaea29170b6a0748819c9d02271746a20d81a5f3efca17">+12/-12</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>api_definition.go</strong><dd><code>Update API
    definition to use new path matching config</code>&nbsp; &nbsp; &nbsp;
    &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-0cf80174bbafb36f6d4f4308ebbd971b2833b76a936bad568220aa1a4ba0ee8b">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access.go</strong><dd><code>Refactor
    middleware to use updated path matching config</code>&nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    gateway/mw_granular_access.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br> <li> Refactored pattern preparation using
    <code>PreparePathRegexp</code>.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-618f7d55751d572562a29506a13beba2da969436e974f8b51df7d9708c925436">+3/-9</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>session_manager.go</strong><dd><code>Update session
    manager for new path matching config</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/session_manager.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-e6b40a285464cd86736e970c4c0b320b44c75b18b363d38c200e9a9d36cdabb6">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>schema.json</strong><dd><code>Update JSON schema for
    path matching configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    cli/linter/schema.json
    
    - Renamed JSON schema fields for path matching options.
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-103cec746d3e61d391c5a67c171963f66fea65d651d704d5540e60aa5d574f46">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    </table></td></tr><tr><td><strong>Tests</strong></td><td><table>
    <tr>
      <td>
        <details>
    <summary><strong>api_definition_test.go</strong><dd><code>Update test
    configuration for path prefix matching</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition_test.go
    
    - Modified test configuration to use `EnablePathPrefixMatching`.
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-2394daab6fdc5f8dc234699c80c0548947ee3d68d2e33858258d73a8b5eb6f44">+1/-1</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access_test.go</strong><dd><code>Update
    middleware test for path prefix matching</code>&nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/mw_granular_access_test.go
    
    - Modified test configuration to use `EnablePathPrefixMatching`.
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-8e0d7cfef26688edd7d08334d955039dab5deb3caf860d29eff6d09894eaba20">+1/-1</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    </table></td></tr></tr></tbody></table>
    
    ___
    
    > 💡 **PR-Agent usage**:
    >Comment `/help` on the PR to get a list of all available PR-Agent tools
    and their descriptions
    
    ---------
    
    Co-authored-by: Tit Petric <[email protected]>
    titpetric added a commit that referenced this pull request Sep 13, 2024
    …pport mux params on legacy (#6510)
    
    [TT-12865] Rename config parameter, update usage, support mux params on
    legacy (#6506)
    
    enhancement
    
    ___
    
    - Renamed configuration fields `EnablePrefixMatching` and
    `EnableSuffixMatching` to `EnablePathPrefixMatching` and
    `EnablePathSuffixMatching` respectively, across multiple files.
    - Updated comments and documentation to reflect the new naming
    conventions.
    - Modified test cases to use the updated configuration fields.
    - Refactored middleware and session manager logic to accommodate the new
    path matching configuration.
    
    ___
    
    <table><thead><tr><th></th><th align="left">Relevant
    
    files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><table>
    <tr>
      <td>
        <details>
    <summary><strong>config.go</strong><dd><code>Rename configuration fields
    for path matching options</code>&nbsp; &nbsp; &nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    config/config.go
    
    <li>Renamed <code>EnablePrefixMatching</code> to
    <code>EnablePathPrefixMatching</code>.<br> <li> Renamed
    <code>EnableSuffixMatching</code> to
    <code>EnablePathSuffixMatching</code>.<br> <li> Updated comments to
    reflect the new naming conventions.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-fe44f09c4d5977b5f5eaea29170b6a0748819c9d02271746a20d81a5f3efca17">+12/-12</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>api_definition.go</strong><dd><code>Update API
    definition to use new path matching config</code>&nbsp; &nbsp; &nbsp;
    &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-0cf80174bbafb36f6d4f4308ebbd971b2833b76a936bad568220aa1a4ba0ee8b">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access.go</strong><dd><code>Refactor
    middleware to use updated path matching config</code>&nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    gateway/mw_granular_access.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br> <li> Refactored pattern preparation using
    <code>PreparePathRegexp</code>.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-618f7d55751d572562a29506a13beba2da969436e974f8b51df7d9708c925436">+3/-9</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>session_manager.go</strong><dd><code>Update session
    manager for new path matching config</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/session_manager.go
    
    <li>Updated variable names to use new path matching configuration
    fields.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-e6b40a285464cd86736e970c4c0b320b44c75b18b363d38c200e9a9d36cdabb6">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>schema.json</strong><dd><code>Update JSON schema for
    path matching configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    cli/linter/schema.json
    
    - Renamed JSON schema fields for path matching options.
    
    </details>
    
      </td> <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-103cec746d3e61d391c5a67c171963f66fea65d651d704d5540e60aa5d574f46">+2/-2</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    </table></td></tr><tr><td><strong>Tests</strong></td><td><table> <tr>
      <td>
        <details>
    <summary><strong>api_definition_test.go</strong><dd><code>Update test
    configuration for path prefix matching</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition_test.go
    
    - Modified test configuration to use `EnablePathPrefixMatching`.
    
    </details>
    
      </td> <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-2394daab6fdc5f8dc234699c80c0548947ee3d68d2e33858258d73a8b5eb6f44">+1/-1</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access_test.go</strong><dd><code>Update
    middleware test for path prefix matching</code>&nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr>
    
    gateway/mw_granular_access_test.go
    
    - Modified test configuration to use `EnablePathPrefixMatching`.
    
    </details>
    
      </td> <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6506/files#diff-8e0d7cfef26688edd7d08334d955039dab5deb3caf860d29eff6d09894eaba20">+1/-1</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    </table></td></tr></tr></tbody></table>
    
    ___
    
    > 💡 **PR-Agent usage**:
    >Comment `/help` on the PR to get a list of all available PR-Agent tools
    and their descriptions
    
    ---------
    
    [TT-12865]:
    
    https://tyktech.atlassian.net/browse/TT-12865?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
    
    ___
    
    Enhancement, Tests
    
    ___
    
    - Introduced new configuration options `EnablePathPrefixMatching` and
    `EnablePathSuffixMatching` to enhance URL path matching capabilities.
    - Refactored URLSpec and related logic to support the new path matching
    configuration.
    - Updated middleware and session management to utilize the new path
    matching options.
    - Added comprehensive tests for the new path matching logic, including
    regression tests for issue 12865.
    - Improved logging and error handling in path matching processes.
    
    ___
    
    <table><thead><tr><th></th><th align="left">Relevant
    files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><details><summary>6
    files</summary><table>
    <tr>
      <td>
        <details>
    <summary><strong>config.go</strong><dd><code>Add configuration for path
    prefix and suffix matching</code>&nbsp; &nbsp; &nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    config/config.go
    
    <li>Added new configuration fields <code>EnablePathPrefixMatching</code>
    and <br><code>EnablePathSuffixMatching</code>.<br> <li> Updated comments
    to explain the new path matching configuration.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-fe44f09c4d5977b5f5eaea29170b6a0748819c9d02271746a20d81a5f3efca17">+43/-0</a>&nbsp;
    &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>api_definition.go</strong><dd><code>Refactor URLSpec
    and update path matching logic</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr>
    
    gateway/api_definition.go
    
    <li>Refactored URLSpec to use private fields and methods.<br> <li>
    Updated path matching logic to support new configuration.<br> <li>
    Renamed several functions for clarity.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-0cf80174bbafb36f6d4f4308ebbd971b2833b76a936bad568220aa1a4ba0ee8b">+47/-142</a></td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>model_apispec.go</strong><dd><code>Refactor and
    deprecate CheckSpecMatchesStatus</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/model_apispec.go
    
    <li>Moved <code>CheckSpecMatchesStatus</code> to a separate file and
    deprecated it.<br> <li> Added <code>FindSpecMatchesStatus</code> for
    improved status checking.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-80c49b9bdb411a3d5a4706ec3ff138ef44154d0306040c19eba1cb5559f199d6">+75/-0</a>&nbsp;
    &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>model_urlspec.go</strong><dd><code>Add path and method
    matching methods to URLSpec</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr>
    
    gateway/model_urlspec.go
    
    <li>Added new methods to URLSpec for matching paths and methods.<br>
    <li> Deprecated <code>modeSpecificSpec</code> method.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-ed766dd1814a557a1943cd3483c6ef511ad1b8febc7bd59982792d0ab7e23cff">+120/-0</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access.go</strong><dd><code>Update
    GranularAccessMiddleware for new path matching</code>&nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/mw_granular_access.go
    
    <li>Updated middleware to use new path matching configuration.<br> <li>
    Improved logging and error handling in path matching.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-618f7d55751d572562a29506a13beba2da969436e974f8b51df7d9708c925436">+74/-20</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mux.go</strong><dd><code>Refactor path regex
    preparation and matching</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr>
    
    internal/httputil/mux.go
    
    <li>Refactored path regex preparation and matching functions.<br> <li>
    Improved caching and handling of mux-style parameters.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-3d9ee5f5e946d72e6f2ae662ff03ee5253bbdc15203d2e4f6e9f46c13011ebf8">+78/-18</a>&nbsp;
    </td>
    
    </tr>
    
    </table></details></td></tr><tr><td><strong>Tests</strong></td><td><details><summary>4
    files</summary><table>
    <tr>
      <td>
        <details>
    <summary><strong>api_definition_test.go</strong><dd><code>Update and add
    test cases for path matching logic</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition_test.go
    
    <li>Updated test cases to reflect changes in path matching logic.<br>
    <li> Added new test cases for path prefix matching.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-2394daab6fdc5f8dc234699c80c0548947ee3d68d2e33858258d73a8b5eb6f44">+12/-12</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access_test.go</strong><dd><code>Add tests
    for GranularAccessMiddleware path matching</code>&nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/mw_granular_access_test.go
    
    <li>Added tests for new path matching logic in
    GranularAccessMiddleware.<br> <li> Updated existing tests to use new
    configuration.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-8e0d7cfef26688edd7d08334d955039dab5deb3caf860d29eff6d09894eaba20">+50/-28</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mux_test.go</strong><dd><code>Add tests for path regex
    preparation and matching</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    internal/httputil/mux_test.go
    
    <li>Added tests for new path matching functions.<br> <li> Updated
    existing tests to reflect changes in regex preparation.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-8f7ce1891e221d7adb9e68f2e951f33edfbde2128187abb6e837ac01952d7888">+112/-14</a></td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>issue_12865_test.go</strong><dd><code>Add regression
    tests for issue 12865</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr>
    
    tests/regression/issue_12865_test.go
    
    <li>Added regression tests for issue 12865.<br> <li> Tested various
    configurations of path prefix and suffix matching.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-1a4f9c47cb4152844d641098b6e7ca8e5e8739eefdec7178f9437750d11db6ec">+171/-0</a>&nbsp;
    </td>
    
    </tr>
    </table></details></td></tr><tr><td><strong>Configuration
    changes</strong></td><td><details><summary>2 files</summary><table> <tr>
      <td>
        <details>
    <summary><strong>test.yml</strong><dd><code>Update test task
    configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    .taskfiles/test.yml
    
    <li>Updated test task to exclude the first package in the list.<br> <li>
    Added a task to merge coverage reports.<br>
    
    </details>
    
      </td>
    <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-f1fbe7f7f14888019b8845634ed008e1c43f6e5a5c0b2707336fc7f8e15a36fb">+2/-1</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>schema.json</strong><dd><code>Update schema for new
    path matching configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    cli/linter/schema.json
    
    - Added new schema fields for path prefix and suffix matching.
    
    </details>
    
      </td> <td><a
    
    href="https://github.com/TykTechnologies/tyk/pull/6507/files#diff-103cec746d3e61d391c5a67c171963f66fea65d651d704d5540e60aa5d574f46">+6/-0</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>
    </table></details></td></tr></tr></tbody></table>
    
    ___
    
    > 💡 **PR-Agent usage**:
    >Comment `/help` on the PR to get a list of all available PR-Agent tools
    and their descriptions
    
    ---------
    
    <!-- Provide a general summary of your changes in the Title above -->
    
    <!-- Describe your changes in detail -->
    
    <!-- This project only accepts pull requests related to open issues. -->
    <!-- If suggesting a new feature or change, please discuss it in an
    issue first. -->
    <!-- If fixing a bug, there should be an issue describing it with steps
    to reproduce. -->
    <!-- OSS: Please link to the issue here. Tyk: please create/link the
    JIRA ticket. -->
    
    <!-- Why is this change required? What problem does it solve? -->
    
    <!-- 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. -->
    
    <!-- What types of changes does your code introduce? Put an `x` in all
    the boxes that apply: -->
    
    - [ ] Bug fix (non-breaking change which fixes an issue)
    - [ ] New feature (non-breaking change which adds functionality)
    - [ ] Breaking change (fix or feature that would cause existing
    functionality to change)
    - [ ] Refactoring or add test (improvements in base code or adds test
    coverage to functionality)
    
    <!-- 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. -->
    
    - [ ] I ensured that the documentation is up to date
    - [ ] I explained why this PR updates go.mod in detail with reasoning
    why it's required
    - [ ] I would like a code coverage CI quality gate exception and have
    explained why
    
    [TT-12865]:
    https://tyktech.atlassian.net/browse/TT-12865?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
    [TT-12865]:
    https://tyktech.atlassian.net/browse/TT-12865?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
    
    ___
    
    Enhancement, Tests
    
    ___
    
    - Introduced new configuration fields `EnablePathPrefixMatching` and
    `EnablePathSuffixMatching` to enhance URL path matching capabilities.
    - Refactored URLSpec and related logic to support the new path matching
    configurations, improving error handling and logging.
    - Updated and added new test cases to cover the new path matching
    options, ensuring comprehensive test coverage.
    - Implemented utility functions for handling path regex preparation and
    matching, with caching for improved performance.
    - Added regression tests for issue 12865, verifying the correct behavior
    of the new path matching configurations.
    
    ___
    
    <table><thead><tr><th></th><th align="left">Relevant
    files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><details><summary>5
    files</summary><table>
    <tr>
      <td>
        <details>
    <summary><strong>config.go</strong><dd><code>Add new configuration
    fields for path matching</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    config/config.go
    
    <li>Introduced new configuration fields
    <code>EnablePathPrefixMatching</code> and
    <br><code>EnablePathSuffixMatching</code>.<br> <li> Added detailed
    comments explaining the new path matching <br>configurations.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6510/files#diff-fe44f09c4d5977b5f5eaea29170b6a0748819c9d02271746a20d81a5f3efca17">+43/-0</a>&nbsp;
    &nbsp; </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>api_definition.go</strong><dd><code>Refactor URLSpec
    and enhance path matching logic</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition.go
    
    <li>Refactored URLSpec to use a private field for regex.<br> <li> Added
    logic to handle path prefix and suffix matching.<br> <li> Improved error
    logging for regex compilation.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6510/files#diff-0cf80174bbafb36f6d4f4308ebbd971b2833b76a936bad568220aa1a4ba0ee8b">+55/-166</a></td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access.go</strong><dd><code>Enhance
    GranularAccessMiddleware with path matching
    options</code></dd></summary>
    <hr>
    
    gateway/mw_granular_access.go
    
    <li>Enhanced GranularAccessMiddleware to support new path matching
    <br>options.<br> <li> Improved logging for access checks.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6510/files#diff-618f7d55751d572562a29506a13beba2da969436e974f8b51df7d9708c925436">+79/-12</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mux.go</strong><dd><code>Add utility functions for path
    regex handling</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    internal/httputil/mux.go
    
    <li>Introduced utility functions for path regex preparation and
    matching.<br> <li> Implemented caching for path regex patterns.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6510/files#diff-3d9ee5f5e946d72e6f2ae662ff03ee5253bbdc15203d2e4f6e9f46c13011ebf8">+139/-0</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>strings.go</strong><dd><code>Implement concurrency-safe
    string map</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    internal/maps/strings.go
    
    <li>Introduced a concurrency-safe map for string storage.<br> <li>
    Provided methods for setting and getting values.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6510/files#diff-5fa5e244ede81be68269555e950af79079de58236fe9c0e67e6f01a602d04dca">+34/-0</a>&nbsp;
    &nbsp; </td>
    
    </tr>
    
    </table></details></td></tr><tr><td><strong>Tests</strong></td><td><details><summary>5
    files</summary><table>
    <tr>
      <td>
        <details>
    <summary><strong>api_definition_test.go</strong><dd><code>Update and add
    tests for path matching configurations</code>&nbsp; &nbsp; &nbsp; &nbsp;
    </dd></summary>
    <hr>
    
    gateway/api_definition_test.go
    
    <li>Updated test cases to reflect new path matching configurations.<br>
    <li> Added new tests for prefix and suffix matching.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6510/files#diff-2394daab6fdc5f8dc234699c80c0548947ee3d68d2e33858258d73a8b5eb6f44">+16/-33</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access_test.go</strong><dd><code>Add tests
    for GranularAccessMiddleware path matching</code>&nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/mw_granular_access_test.go
    
    <li>Added tests for GranularAccessMiddleware with new path matching
    <br>configurations.<br> <li> Ensured coverage for both prefix and suffix
    matching scenarios.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6510/files#diff-8e0d7cfef26688edd7d08334d955039dab5deb3caf860d29eff6d09894eaba20">+50/-24</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>mux_test.go</strong><dd><code>Add tests for path regex
    utilities</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    internal/httputil/mux_test.go
    
    <li>Added tests for path regex preparation and matching utilities.<br>
    <li> Verified caching behavior for regex patterns.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6510/files#diff-8f7ce1891e221d7adb9e68f2e951f33edfbde2128187abb6e837ac01952d7888">+162/-0</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>issue_12865_test.go</strong><dd><code>Add regression
    tests for issue 12865</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    tests/regression/issue_12865_test.go
    
    <li>Added regression tests for issue 12865.<br> <li> Tested various path
    matching configurations.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6510/files#diff-1a4f9c47cb4152844d641098b6e7ca8e5e8739eefdec7178f9437750d11db6ec">+171/-0</a>&nbsp;
    </td>
    
    </tr>
    
    <tr>
      <td>
        <details>
    <summary><strong>regression_test.go</strong><dd><code>Refactor and test
    API spec loading utilities</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    tests/regression/regression_test.go
    
    <li>Refactored utility functions for loading API specs.<br> <li> Added
    test for loading API specs with environment variable
    <br>replacement.<br>
    
    </details>
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6510/files#diff-24d0ac1f4eb4bb6e33d0db26aca8ef96aef2b67fd2730fcde6e952ce3d894696">+23/-3</a>&nbsp;
    &nbsp; </td>
    
    </tr>
    </table></details></td></tr></tr></tbody></table>
    
    ___
    
    > 💡 **PR-Agent usage**:
    >Comment `/help` on the PR to get a list of all available PR-Agent tools
    and their descriptions
    
    ---------
    
    Co-authored-by: Leonid Bugaev <[email protected]>
    Co-authored-by: Tit Petric <[email protected]>
    buger pushed a commit that referenced this pull request Sep 13, 2024
    ### **User description**
    <!-- Provide a general summary of your changes in the Title above -->
    
    ## Description
    Backport critical fixes from PRs in order
    #6480
    #6437
    #6475
    #6506
    
    
    
    ## Related Issue
    https://tyktech.atlassian.net/browse/TT-1944
    https://tyktech.atlassian.net/browse/TT-12550
    https://tyktech.atlassian.net/browse/TT-12865
    
    ## Motivation and Context
    
    <!-- Why is this change required? What problem does it solve? -->
    
    ## 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. -->
    
    ## Screenshots (if appropriate)
    
    ## Types of changes
    
    <!-- What types of changes does your code introduce? Put an `x` in all
    the boxes that apply: -->
    
    - [ ] Bug fix (non-breaking change which fixes an issue)
    - [ ] New feature (non-breaking change which adds functionality)
    - [ ] Breaking change (fix or feature that would cause existing
    functionality to change)
    - [ ] 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. -->
    
    - [ ] I ensured that the documentation is up to date
    - [ ] I explained why this PR updates go.mod in detail with reasoning
    why it's required
    - [ ] I would like a code coverage CI quality gate exception and have
    explained why
    
    
    ___
    
    ### **PR Type**
    Enhancement, Bug fix, Tests
    
    
    ___
    
    ### **Description**
    - Introduced new configuration options for path prefix and suffix
    matching to enhance URL matching capabilities.
    - Refactored URLSpec to improve regex generation and logging for URL
    matching.
    - Enhanced GranularAccessMiddleware with improved URL matching logic and
    error handling.
    - Added utility functions for handling path regex preparation and
    matching, with caching for performance.
    - Updated and added test cases to verify new URL matching logic and
    configurations.
    - Added regression tests for issue 12865 to ensure stability and
    correctness of new features.
    
    
    ___
    
    
    
    ### **Changes walkthrough** 📝
    <table><thead><tr><th></th><th align="left">Relevant
    files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><details><summary>4
    files</summary><table>
    <tr>
      <td>
        <details>
    <summary><strong>config.go</strong><dd><code>Introduce path prefix and
    suffix matching configuration</code>&nbsp; &nbsp; </dd></summary>
    <hr>
    
    config/config.go
    
    <li>Added new configuration options for path prefix and suffix
    matching.<br> <li> Enhanced documentation for new URL matching
    behavior.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6513/files#diff-fe44f09c4d5977b5f5eaea29170b6a0748819c9d02271746a20d81a5f3efca17">+43/-0</a>&nbsp;
    &nbsp; </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>api_definition.go</strong><dd><code>Refactor and
    enhance URLSpec for better URL matching</code>&nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition.go
    
    <li>Refactored URLSpec to use private fields.<br> <li> Enhanced regex
    generation for URL matching.<br> <li> Improved logging for URL matching
    process.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6513/files#diff-0cf80174bbafb36f6d4f4308ebbd971b2833b76a936bad568220aa1a4ba0ee8b">+52/-36</a>&nbsp;
    </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access.go</strong><dd><code>Enhance URL
    matching and error handling in
    GranularAccessMiddleware</code></dd></summary>
    <hr>
    
    gateway/mw_granular_access.go
    
    <li>Enhanced URL matching in GranularAccessMiddleware.<br> <li> Improved
    error handling and logging.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6513/files#diff-618f7d55751d572562a29506a13beba2da969436e974f8b51df7d9708c925436">+79/-12</a>&nbsp;
    </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>mux.go</strong><dd><code>Add utility functions for path
    regex handling</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    internal/httputil/mux.go
    
    <li>Introduced utility functions for path regex preparation and
    matching.<br> <li> Implemented caching for path regex patterns.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6513/files#diff-3d9ee5f5e946d72e6f2ae662ff03ee5253bbdc15203d2e4f6e9f46c13011ebf8">+139/-0</a>&nbsp;
    </td>
    
    </tr>                    
    
    </table></details></td></tr><tr><td><strong>Tests</strong></td><td><details><summary>4
    files</summary><table>
    <tr>
      <td>
        <details>
    <summary><strong>api_definition_test.go</strong><dd><code>Update and add
    test cases for enhanced URL matching</code>&nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; </dd></summary>
    <hr>
    
    gateway/api_definition_test.go
    
    <li>Updated test cases to reflect changes in URL matching logic.<br>
    <li> Added new test scenarios for prefix and suffix matching.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6513/files#diff-2394daab6fdc5f8dc234699c80c0548947ee3d68d2e33858258d73a8b5eb6f44">+15/-33</a>&nbsp;
    </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>mw_granular_access_test.go</strong><dd><code>Add tests
    for enhanced URL matching in
    GranularAccessMiddleware</code></dd></summary>
    <hr>
    
    gateway/mw_granular_access_test.go
    
    <li>Added tests for new URL matching logic in
    GranularAccessMiddleware.<br> <li> Verified behavior with different path
    configurations.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6513/files#diff-8e0d7cfef26688edd7d08334d955039dab5deb3caf860d29eff6d09894eaba20">+50/-24</a>&nbsp;
    </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>mux_test.go</strong><dd><code>Add tests for path regex
    utility functions</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    internal/httputil/mux_test.go
    
    <li>Added tests for new path regex utility functions.<br> <li> Verified
    regex preparation and matching logic.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6513/files#diff-8f7ce1891e221d7adb9e68f2e951f33edfbde2128187abb6e837ac01952d7888">+162/-0</a>&nbsp;
    </td>
    
    </tr>                    
    
    <tr>
      <td>
        <details>
    <summary><strong>issue_12865_test.go</strong><dd><code>Add regression
    tests for issue 12865</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    tests/regression/issue_12865_test.go
    
    <li>Added regression tests for issue 12865.<br> <li> Tested various path
    matching configurations.<br>
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6513/files#diff-1a4f9c47cb4152844d641098b6e7ca8e5e8739eefdec7178f9437750d11db6ec">+171/-0</a>&nbsp;
    </td>
    
    </tr>                    
    </table></details></td></tr><tr><td><strong>Configuration
    changes</strong></td><td><details><summary>1 files</summary><table>
    <tr>
      <td>
        <details>
    <summary><strong>schema.json</strong><dd><code>Update schema for new
    path matching options</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
    <hr>
    
    cli/linter/schema.json
    
    - Updated schema to include new path matching configuration options.
    
    
    
    </details>
    
    
      </td>
    <td><a
    href="https://github.com/TykTechnologies/tyk/pull/6513/files#diff-103cec746d3e61d391c5a67c171963f66fea65d651d704d5540e60aa5d574f46">+6/-0</a>&nbsp;
    &nbsp; &nbsp; </td>
    
    </tr>                    
    </table></details></td></tr></tr></tbody></table>
    
    ___
    
    > 💡 **PR-Agent usage**:
    >Comment `/help` on the PR to get a list of all available PR-Agent tools
    and their descriptions
    
    ---------
    
    Co-authored-by: Tit Petric <[email protected]>
    Co-authored-by: Tit Petric <[email protected]>
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Projects
    None yet
    Development

    Successfully merging this pull request may close these issues.

    2 participants