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

[Feature] Add handlers registry #695

Open
bsless opened this issue Aug 26, 2024 · 1 comment
Open

[Feature] Add handlers registry #695

bsless opened this issue Aug 26, 2024 · 1 comment

Comments

@bsless
Copy link
Contributor

bsless commented Aug 26, 2024

Just like middleware registry, but with a few open questions:

  • Should it be an opt of ring.core/router?
  • How should resolution be performed? Just postwalk and look for :handler?
    • Does that risk mangling input data?
    • Same for metadata (meta merge)
    • Can be done after merge but before compilation
  • Belong in core or ring?
@ikitommi
Copy link
Member

Quick comments:

  • base into reitit.middleware which defines concept of :handler, ring uses it
  • :handler paths are known in the :compile hook, different for middleware & ring, this is the way
  • maybe IntoHandler protocol?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: No status
Development

No branches or pull requests

2 participants