eclipse-ee4j / eclipse-ee4j/jersey
JettyConnector : add support for listener of Jetty request creation, to support advanced tracking
- Dominant language
- Java
- Stars
- 730
- Forks
- 382
- PR merge metrics
- No merged PRs in 30d
Description
Hello!
In case of timeout, I would like to have a bit more information than what is provided by default ; specifically, I want to know if the call was sent to the server, or if it timed out in the request queue.
I asked this question on the jetty support channel directly, and found a way to do this, but it is hacky : https://github.com/eclipse/jetty.project/issues/4827
Essentially, I need to inject to JettyConnector a subclass of httpClient, to be able to attach listeners to the Jetty Requests created.
When asking for ideas of improvements, I received the advice of asking here for support of some kind of hook that would make this less dirty.
What I have in mind is an option to add to JettyConnector a listener of request creation, that is called just after creating the Jetty request. This way, I would not need to subclass the httpClient.
What do you think? If this seems reasonable to you, I can propose an implementation via a pull request.
Thank you!
Contributor guide
Research direction
Start with the JettyConnector request-creation path and the Jetty Request listeners described in the issue; review the linked Jetty issue for the current workaround. Determine the hook's API and lifecycle, then verify that callers can observe request creation and distinguish queued timeouts from requests sent to the server.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- backend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100