Skip to content

feat: Add HTTP gateway for SupernodeService with status and services …#107

Merged
mateeullahmalik merged 4 commits intomasterfrom
feat/grpc-gateway-rest-api
Jul 31, 2025
Merged

feat: Add HTTP gateway for SupernodeService with status and services …#107
mateeullahmalik merged 4 commits intomasterfrom
feat/grpc-gateway-rest-api

Conversation

@mateeullahmalik
Copy link
Collaborator

…endpoints

@a-ok123 a-ok123 requested review from a-ok123 and Copilot July 31, 2025 06:33
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR adds an HTTP gateway for the SupernodeService, introducing REST endpoints for status and services information alongside the existing gRPC service. It includes field renaming for better semantic clarity and infrastructure for HTTP-based API access.

  • Adds HTTP gateway server with REST endpoints at /api/v1/status and /api/v1/services
  • Renames Services to RunningTasks and AvailableServices to RegisteredServices for semantic clarity
  • Introduces new ListServices endpoint to expose available gRPC service methods

Reviewed Changes

Copilot reviewed 25 out of 25 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
proto/supernode/supernode.proto Adds HTTP annotations and new ListServices RPC with field renames
supernode/node/supernode/gateway/ New HTTP gateway implementation with Swagger UI support
supernode/config/ Adds gateway_port configuration option
supernode/cmd/ Updates initialization and startup to include gateway server
Multiple test files Updates tests to use renamed fields (Services → RunningTasks)
Generated files Updated protobuf and gRPC gateway generated code

Comment on lines +183 to +190
"services": {
"type": "array",
"items": {
"type": "object",
"$ref": "#/definitions/StatusResponseServiceTasks"
}
},
"availableServices": {
Copy link

Copilot AI Jul 31, 2025

Choose a reason for hiding this comment

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

The swagger.json file contains outdated field names. The 'services' field should be 'runningTasks' and 'availableServices' should be 'registeredServices' to match the protobuf changes.

Suggested change
"services": {
"type": "array",
"items": {
"type": "object",
"$ref": "#/definitions/StatusResponseServiceTasks"
}
},
"availableServices": {
"runningTasks": {
"type": "array",
"items": {
"type": "object",
"$ref": "#/definitions/StatusResponseServiceTasks"
}
},
"registeredServices": {

Copilot uses AI. Check for mistakes.
a-ok123
a-ok123 previously approved these changes Jul 31, 2025
@mateeullahmalik mateeullahmalik merged commit 76055c3 into master Jul 31, 2025
7 checks passed
@mateeullahmalik mateeullahmalik deleted the feat/grpc-gateway-rest-api branch August 12, 2025 11:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants