-
Notifications
You must be signed in to change notification settings - Fork 671
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
4.3.10 is a major breaking change in behavior #454
Comments
i'm facing the same issue @alexanderbh is facing right now if you have staff/admin/{proxy+} at your SAM template it doesn't make sense to use /staff/admin/list at the lambda code level. That means that your lambda can't be setup to handle a different event on a different path. Your lambda code should be agnostic of the mount path you are using on the Api Gateway |
Exactly this. We have the same lambda function on different API Gateway proxy endpoints. We have one that has an authorizer called But now I cannot make a single lambda listening for the proxy part (/list) and use it both places. Now the lambda is forever bound to the exact path prefix for the custom domain + what ever URL path you have used in the API Gateway resource. That lambda function is just listening for the proxy part: |
🎉 This issue has been resolved in version 4.3.11 🎉 The release is available on: Your semantic-release bot 📦🚀 |
thank you @brett-vendia and @alexanderbh for fixing this situation so soon. |
Not trying to dig up an ancient thread, but I upgraded from the old aws-serverless-express library to this one and had my API broken by this change. In my API Gateway config, I have -- |
## [4.3.11](CodeGenieApp/serverless-express@v4.3.10...v4.3.11) (2021-08-31) ### Bug Fixes * revert [#441](CodeGenieApp/serverless-express#441) ([#455](CodeGenieApp/serverless-express#455)) ([87aa26f](CodeGenieApp/serverless-express@87aa26f)), closes [#454](CodeGenieApp/serverless-express#454)
Having the same exact issue, I think we should reopen / create a new issue for this. |
4.3.10 is breaking ALL our services. It is a patch version and we they are updated automatically. Why is this change not a major version bump? It might have fixed an "issue". But if the issue is how everyone have setup their existing routes then fixing this is a breaking change.
45edbfa
It might "error out with 404" if you are setting up a new service. But for everyone else using this library. And have routes that works. This will totally mess it up.
In my event handler I have
staff/admin/{proxy+}
and in my serverless-express server I have a route that simply matches on for example/list
. That works great in 4.3.9 or below. That is how everyone have managed until now. It will match the pathstaff/admin/list
. Great.It might "error out with 404" if you make your route like
/staff/admin/list
. But you have to think about existing users. We are using 4.3.9 as it is. Changing this "issue" (I like it better if I can just route on the proxy part alone so it is not an improvement for me) breaks it for everyone using proxy on 4.3.9.@selvendranayyaswamy
@selvendran.ayyaswamy
The text was updated successfully, but these errors were encountered: