Skip to content

Fix multi level match any routes #1413

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

Merged

Conversation

lammel
Copy link
Contributor

@lammel lammel commented Oct 3, 2019

This is a pull request for issue #1412 which probably also fixes #1406 .

The benchmarks also indicate a slight improvement for the route tests (although that was not intential). So this should probably be verified elsewhere too.

As a side-effect also a small issue for the router not returning the correct remaining path in c.Param("*") with overlapping any routes has been fixed (and a test added)

The route tests have also been improved which can also be provided as part of this PR are separately.

@codecov
Copy link

codecov bot commented Oct 3, 2019

Codecov Report

Merging #1413 into master will increase coverage by 0.27%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1413      +/-   ##
==========================================
+ Coverage   84.09%   84.36%   +0.27%     
==========================================
  Files          27       27              
  Lines        2068     2079      +11     
==========================================
+ Hits         1739     1754      +15     
+ Misses        214      212       -2     
+ Partials      115      113       -2
Impacted Files Coverage Δ
router.go 96.3% <100%> (+1.69%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update d286e28...8bfed69. Read the comment docs.

@lammel
Copy link
Contributor Author

lammel commented Oct 4, 2019

The travis CI error is not related to this PR is seems.
No changes to the modules (go.mod) have been done, so that seems to be unrelated.

The command "go get -v golang.org/x/lint/golint" failed and exited with 1 during 

Let me know if a should push again.

@lammel lammel force-pushed the bugfix/1412-route-matchany-multilevel branch from c4bc098 to ccf6f1a Compare October 16, 2019 20:35
@lammel
Copy link
Contributor Author

lammel commented Oct 16, 2019

Rebased on master (v4.1.11) now.

An additional issue has been fixed in route insert, which did not correctly update the parent node on node split (which resolves an issue with adding routes in the wrong order, causing a root-node split, tests added for that case).

@stale
Copy link

stale bot commented Dec 15, 2019

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@asahasrabuddhe
Copy link
Contributor

Please re-open this. We need this merged.

@vishr vishr reopened this Dec 30, 2019
@stale stale bot removed the wontfix label Dec 30, 2019
@vishr vishr merged commit 8bfed69 into labstack:master Dec 30, 2019
@asahasrabuddhe
Copy link
Contributor

Thank you very much!

@lammel lammel deleted the bugfix/1412-route-matchany-multilevel branch January 2, 2020 18:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

static routing and dynamic routing conflicts problems.
3 participants