Skip to content

feat(middleware_factory): support router #954

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

Closed
wants to merge 1 commit into from

Conversation

BVMiko
Copy link
Contributor

@BVMiko BVMiko commented Jan 12, 2022

Issue #, if available:
#953

Description of changes:

The changes needed for lambda_handler_decorator to support routers are only to modify the arguments of the inner wrapper and its invocation, so I modified it to accept arbitrary arguments.

Due to the difference in signature (and function name), it may be preferable to instead move this to a clone named router_decorator instead of modifying the original lambda_handler_decorator. If you would like me to do so, let me know and I can make the change.

Checklist

Breaking change checklist

There may be potential issues with positional arguments if we reuse the same decorator.

RFC issue #:

  • Migration process documented
  • Implement warnings (if it can live side by side)

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@pull-request-size pull-request-size bot added the size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. label Jan 12, 2022
@github-actions github-actions bot added the feature New feature or functionality label Jan 12, 2022
Copy link
Contributor

@heitorlessa heitorlessa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you duplicate the decorator factory into a new function named decorator?

That will prevent confusing anyone reading someone's else coding that uses both of them in different ways. It's also easier to update the docs with a new section as the more explicit we are.

Thank you so much.

@heitorlessa heitorlessa added the p3 label Jan 31, 2022
@heitorlessa
Copy link
Contributor

following up in case you missed the comment above

@heitorlessa heitorlessa force-pushed the develop branch 5 times, most recently from 742ccf5 to b582992 Compare July 13, 2022 11:59
@BVMiko BVMiko requested a review from a team as a code owner July 29, 2022 14:51
@BVMiko BVMiko requested review from mploski and removed request for a team July 29, 2022 14:51
@heitorlessa heitorlessa removed the p3 label Aug 2, 2022
@heitorlessa heitorlessa added middleware_factory Middleware factory utility and removed area/middleware_factory labels Nov 9, 2022
@leandrodamascena
Copy link
Contributor

Hi everyone! We are working on issue #1955 to add router support to Middleware Factory and other changes.

As this PR has not been updated for some time and issue #1955 will add this support and some other improvements, so we are closing this PR.

Thank you all and if you think that something can be done in this PR, feel free to reopen it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature or functionality middleware_factory Middleware factory utility size/XS Denotes a PR that changes 0-9 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants