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

WIP: dropshot support for multiple API versions #862

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft

Conversation

ahl
Copy link
Collaborator

@ahl ahl commented Dec 29, 2023

I think these are most of the steps:

  • #[endpoint] macro parsing
  • macro creation of versioned endpoints
  • route tree creation of multiple versions including detection of overlapping version ranges
  • enumeration of versions
  • proper routing to versioned handlers
  • extraction of OpenAPI document for a particular version

Here's my proposal for how we parse versions with the proc macro:

#[endpoint {
    method = GET,
    path = "/testing/demo1",
    // versions = "1.2.3"..,
    // versions = .."1.2.5",
    versions = "1.2.3".."1.2.5",
}]
async fn demo_handler_args_1(..) {}

@davepacheco
Copy link
Collaborator

Elaborated on the plan here that we discussed a few weeks ago in #869.

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.

None yet

2 participants