Skip to content

RejectRouterHandler.FAIL does not work as intended. #6498

@chickenchickenlove

Description

@chickenchickenlove

Aremeria has three types of RejectRouterHandler.

  • DISABLED
  • WARN
  • FAIL

However, both WARN and FAIL ultimately only produce warning logs, and the server builds successfully.
Therefore, to preserve the intended behavior of FAIL, the server build should fail when FAIL is used.

Server.builder()
                     .virtualHost("foo.com")
                     .rejectedRouteHandler(RejectedRouteHandler.FAIL)
                     .service("/foo", (ctx, req) -> HttpResponse.of("ok"))
                     .service("/foo", (ctx, req) -> HttpResponse.of("duplicate"));

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions