feat: add federation gateway monitoring and API#109
Open
bansalayush247 wants to merge 5 commits into
Open
Conversation
ec59dcb to
a409641
Compare
- Introduced and methods in the API service to retrieve gateway information based on federation ID and invite code. - Updated API types to include , , and for better structure and type safety. feat(database): create gateway_poll_snapshots table - Added a new table to store snapshots of gateway visibility over time, including fields for federation ID, gateway ID, poll time, and visibility status. feat(federation): implement gateway fetching logic - Implemented to aggregate gateway information from federation peers. - Enhanced the to periodically poll and store gateway data, including metrics for activity and uptime. fix(federation): update gateway listing to include metrics - Modified to return additional metrics such as activity and uptime for specified time windows. - Improved error handling and logging for gateway fetching operations. refactor(federation): adjust module visibility - Changed the visibility of the module to to restrict access to internal components only.
…tus notifications
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.
.envvalues into your shell, then run the server.nix develop.Wait for the gateway monitor to poll.
The default poll interval is 5 minutes, or it can be reduced temporarily for local testing.
Fetch the federation ID and test the gateways endpoint.
Verification
GET /federations/:federation_id/gatewaysreturns the stored gateway list