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

[ISSUE] The routing support is not complete (patch(), options() and any() routing method missing) #80

Open
lestephane opened this issue May 31, 2020 · 0 comments
Assignees

Comments

@lestephane
Copy link

I'd like to capture all requests, regardless of the method used.

##technique 1: map all methods one by one

-> Not possible since patch() and options() method aren't present, so PATCH and OPTIONS request won't be mappable
-> Too verbose

    QuantumMaid quantumMaid = quantumMaid()
        .withHttpMaid(anHttpMaid()
            .get("/*", dumpRequest())
            //.options("/*", dumpRequest())
            //.patch("/*", dumpRequest())
            .post("/*", dumpRequest())
            .put("/*", dumpRequest())
            .delete("/*", dumpRequest()).build())
        .withLocalHostEndpointOnPort(port);

technique 2: catchall any() method

to route everything to one handler

-> Not possible either as there is no such support in httpmaid

    QuantumMaid quantumMaid = quantumMaid()
        .withHttpMaid(anHttpMaid()
            .any("/*", dumpRequest())
        .withLocalHostEndpointOnPort(port);
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

2 participants