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

fix: make sure to strip also base path non pathParameter #555

Merged
merged 3 commits into from
May 8, 2023

Conversation

fossamagna
Copy link

Issue #, if available:

fix #377

Description of changes:

When define resource /users/${proxy+}, request to /users/123 is path as /123. But when mapping /users, request to /users is path as /users not /. It is not symmetry.

BREAKING CHANGE: A handler of defined resource not use pathParameter be also less able to get base path.

Checklist

  • Tests have been added and are passing

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

fossamagna and others added 2 commits October 7, 2022 22:22
When define resource `/users/${proxy+}`,  request to `/users/123` is path as `/123`. But when
mapping `/users`,  request to `/users` is path as `/users` not `/`.  It is not symmetry.

BREAKING CHANGE: A handler of defined resource not use pathParameter be also less able to get base
path.

fix CodeGenieApp#377
@fossamagna
Copy link
Author

@brettstack @brett-vendia
Could you review this pull request?

@brettstack
Copy link
Collaborator

Thanks @fossamagna is this a breaking change?

@fossamagna
Copy link
Author

@brettstack
Thank you for your reply.
I think that breaking change. Since, if a handler of defined resource don't have a custom domain and pathParameter, it is also less able to get base path.

@brettstack brettstack changed the base branch from mainline to v5 May 8, 2023 05:51
@brettstack brettstack merged commit e7017d5 into CodeGenieApp:v5 May 8, 2023
0 of 4 checks passed
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.

Routing to root path does not work correctly when using nested API resources
2 participants