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

Router rewriteMethod property does not work with path prefix #2231

Closed
DiogoFKT opened this issue Apr 25, 2024 · 1 comment
Closed

Router rewriteMethod property does not work with path prefix #2231

DiogoFKT opened this issue Apr 25, 2024 · 1 comment
Assignees

Comments

@DiogoFKT
Copy link
Contributor

router.methodRewriteRules property only works with full path because StringUtils must match string.split("/") item count between full path against configured path prefix

https://github.com/networknt/light-4j/blob/master/utility/src/main/java/com/networknt/utility/StringUtils.java#L1499-L1503

Called here:

https://github.com/networknt/light-4j/blob/2.1.33/proxy-handler/src/main/java/com/networknt/handler/ProxyHandler.java#L627

We need the property to allow only path prefix so to apply to any endpoint that matches the path prefix

@stevehu
Copy link
Contributor

stevehu commented Apr 26, 2024

@DiogoFKT We have the same issue for timeout overwritten as well and it is fixed at the same time. Thanks a lot for pointing it out.

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

No branches or pull requests

2 participants