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

Path param in @Controller #84

Closed
procek69 opened this issue Aug 6, 2016 · 6 comments
Closed

Path param in @Controller #84

procek69 opened this issue Aug 6, 2016 · 6 comments

Comments

@procek69
Copy link

procek69 commented Aug 6, 2016

Feature: Similiar mechanism like in HTTP annotations:

@GET("/{id}/subresources")

but also in

@Controller("/api/resource/{id}/subresource")

@korri123
Copy link
Contributor

Where would the parameters go? would it be mapped to e.g. int id as in your case?

@nmihajlovski
Copy link
Contributor

This is already implemented in v5.2. :)

@nmihajlovski
Copy link
Contributor

E.g. the following code will register a handler for /api/resource/{id}/subresource/abc:

@Controller("/api/resource/{id}/subresource")
public class Ctrl {

    @GET
    public String abc(String id) {
        return id;
    }

}

@korri123
Copy link
Contributor

Ah, I see.
By the way I think it's time to update the TechEmpower benchmarks to more realistic Rapidoid code, they marked it as stripped, also some people are accusing it of being misleading.

@korri123
Copy link
Contributor

Stripped means that it will be hidden by default.

@nmihajlovski
Copy link
Contributor

Thanks, I am aware of the problem, I plan to implement the benchmarks using the high-level API very soon...

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

3 participants