Skip to content

Request hook#5433

Merged
lippserd merged 6 commits intomainfrom
request-hook
Mar 26, 2026
Merged

Request hook#5433
lippserd merged 6 commits intomainfrom
request-hook

Conversation

@jrauh01
Copy link
Copy Markdown
Contributor

@jrauh01 jrauh01 commented Oct 10, 2025

Add a RequestHook that hooks into different states of a request. The implementation starts with hooking into after non xhr requests are dispatched. This is meant to be extended for more more states like for example before a request gets dispatched.

@jrauh01 jrauh01 self-assigned this Oct 10, 2025
@cla-bot cla-bot bot added the cla/signed label Oct 10, 2025
@jrauh01 jrauh01 requested a review from lippserd October 10, 2025 07:30
Copy link
Copy Markdown
Member

@Al2Klimov Al2Klimov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@lippserd, what do you think about the following?

@jrauh01 jrauh01 marked this pull request as draft November 6, 2025 10:48
@jrauh01 jrauh01 marked this pull request as ready for review November 6, 2025 11:45
@jrauh01 jrauh01 force-pushed the request-hook branch 2 times, most recently from c98fc25 to 69a3cba Compare November 17, 2025 11:55
@Al2Klimov Al2Klimov self-requested a review February 16, 2026 15:17
Al2Klimov

This comment was marked as resolved.

jrauh01 added 6 commits March 5, 2026 07:20
Add a hook that hooks into different states of a request. The
implementation starts with hooking into after non xhr requests
are dispatched. This is meant to be extended for more more states
like before a request gets dispatched.
Add a function to the Icinga Web Request that checks whether the
request is sent by auto refresh by checking if the request header
`X-Icinga-Autorefresh` is set.
@jrauh01
Copy link
Copy Markdown
Contributor Author

jrauh01 commented Mar 5, 2026

As this is a new hook, add the new methods just like in #5442:

  • all()
  • register()

I added them and I saw there is already an implementation of Hook\Essentials in #5474 . Depending on what PR will be merged first, the other PR has to be adjusted.

@lippserd lippserd added this to the 2.13 milestone Mar 24, 2026
@lippserd lippserd merged commit 6ae9980 into main Mar 26, 2026
14 checks passed
@lippserd lippserd deleted the request-hook branch March 26, 2026 13:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants