Add webhook routing service and client#1887
Merged
vlad-ivanov-name merged 1 commit intomasterfrom Mar 12, 2026
Merged
Conversation
This commit adds a set of tools for local development of josh commit queue. ### Problem Almost any github app needs to work with webhooks to receive notifications about changes in remote state. Webhooks are set up on github app level, and go to a fixed URL address. When developing an app that needs to receive webhooks, this presents a problem for testing: if you need to frequently restart/recompile the app, you need some sort of a tunnel to route webhooks to your machine. Moveover, without additional tooling, you can only have one webhook receiver at a time and can't e.g. "sniff" webhook payloads for debugging. ### Implementation To solve this, this PR adds a couple of tools that will be used for CQ development. * josh-test-webhook-service: a service that runs on a remote server and listens to github webhooks * josh-test-webhook-client: a crate that lets you connect to that service at any time, and start receiving webhook events over websocket. The webhook target URL never changes, and the client library can connect at any time. Moreover, multiple receivers can connect to listen to webhooks. There are some paid services that accomplish this, but this presents a minimal, and usecase-specific alternative. While this is not intended to be used in production, it's very helpful for testing and has already been tested in a real deployment. Change-Id: If0a6e00de0e2c8211fa27a9bb54910ff6db637ee
91c15ca to
9190146
Compare
christian-schilling
approved these changes
Mar 11, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add webhook routing service and client
This commit adds a set of tools for local development of josh commit
queue.
Problem
Almost any github app needs to work with webhooks to receive
notifications about changes in remote state. Webhooks are set up on
github app level, and go to a fixed URL address.
When developing an app that needs to receive webhooks, this presents a
problem for testing: if you need to frequently restart/recompile the
app, you need some sort of a tunnel to route webhooks to your machine.
Moveover, without additional tooling, you can only have one webhook
receiver at a time and can't e.g. "sniff" webhook payloads for
debugging.
Implementation
To solve this, this PR adds a couple of tools that will be used for CQ
development.
listens to github webhooks
service at any time, and start receiving webhook events over websocket.
The webhook target URL never changes, and the client library can connect
at any time. Moreover, multiple receivers can connect to listen to
webhooks.
There are some paid services that accomplish this, but this presents a
minimal, and usecase-specific alternative.
While this is not intended to be used in production, it's very helpful
for testing and has already been tested in a real deployment.
Change-Id: If0a6e00de0e2c8211fa27a9bb54910ff6db637ee