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

Make Server::setDefaultHandler and Server::setErrorHandler arguments consistent #12802

Open
scrat98 opened this issue Feb 18, 2025 · 0 comments

Comments

@scrat98
Copy link
Contributor

scrat98 commented Feb 18, 2025

Jetty version(s)
12.0.16

Enhancement Description
There is an inconsistency in arguments between Server::setDefaultHandler and Server::setErrorHandler.

  • Server::setDefaultHandler accepts org.eclipse.jetty.server.Handler
  • Server::setErrorHandler accepts org.eclipse.jetty.server.Request.Handler

I would like to use in Application code only org.eclipse.jetty.server.Handler and if I do so and use it with Server::setErrorHandler then I'll get a warning
WARN o.e.jetty.server.Handler$Abstract - No Server set for csclhs.UnhandledErrorsHandler@5ace1ed4{STARTING} and due to this I need to implement my hanlder as a org.eclipse.jetty.server.Request.Handler to suppress this warning.

Nothing serious, but I think it should be easy to change.

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

No branches or pull requests

1 participant