Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[REST] Add support for REST services #87

Closed
6 tasks
Olshansk opened this issue Dec 6, 2024 · 0 comments
Closed
6 tasks

[REST] Add support for REST services #87

Olshansk opened this issue Dec 6, 2024 · 0 comments
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@Olshansk
Copy link
Contributor

Olshansk commented Dec 6, 2024

Objective

Add support for any REST service in PATH.

Origin Document

In pokt-network/poktroll/pull/879, we removed AppGateServer in the shannon repo in favor of PATH.

Part of this change meant removing support for REST because PATH does not have it yet.

Goals

  • Add support for REST services
  • Prepare for other protocols (gRPC, Websockets) in PATH
  • Create an example set of PRs on how to add support for new protocol types: implementation, documentation, configs, examples, etc...

Deliverables

  • Implement support for rest services
  • Document a NEW page in path.grove.city explaining how to configure and use REST services
  • Provide an example (cheatsheet + configs) on how to run a REST service in PATH
  • Update the poktroll to revert all the TODOs added in pokt-
    network/poktroll/pull/879
    • Re-enable the LLM services
    • Re-enable the REST E2E tests

Non-goals / Non-deliverables

  • TODO

Creator: @Olshansk
Co-Owners: @commoddity @red-0ne

@Olshansk Olshansk added the enhancement New feature or request label Dec 6, 2024
@Olshansk Olshansk moved this to 🔖 Ready in Path Roadmap Dec 6, 2024
@Olshansk Olshansk added this to the Portal to PATH Migration milestone Dec 6, 2024
@Olshansk Olshansk moved this from 🔖 Ready to 👀 In review in Path Roadmap Jan 28, 2025
@Olshansk Olshansk closed this as completed by moving to 👀 In review in Path Roadmap Jan 28, 2025
@github-project-automation github-project-automation bot moved this from 👀 In review to ✅ Done in Path Roadmap Jan 28, 2025
commoddity added a commit that referenced this issue Feb 5, 2025
…tBFT & The Interchain (#149)

## Summary

Adds a CometBFT QoS implementation.

Spec Reference: https://docs.cometbft.com/v0.38/rpc

### QoS Checks

- `/health` - Simple node heartbeat. Returns empty response if node
healthy or error response if node unhealthy.
- `/status` - Returns status including node info, pubkey, latest block
hash, app hash, block height and time. **Only used to get latest block
height.**

### Screenshots

The following screenshots show PATH functioning for `cometbft` on
Shannon after `cometbft` service added with Supplier backend URL set to
https://rpc.cosmos.directory/cosmoshub

**1. `/health` Request**
<img width="484" alt="Screenshot 2025-01-24 at 19 26 33"
src="https://github.com/user-attachments/assets/7a8ab462-0b01-41c2-a716-00cf0f09ab02"
/>

**2. `/status` Request**
<img width="574" alt="Screenshot 2025-01-24 at 19 26 50"
src="https://github.com/user-attachments/assets/befd23e4-a5e5-49cc-af31-83dd35ac43df"
/>

**3. `header?height=24106587` Request**
<img width="594" alt="Screenshot 2025-01-24 at 19 27 07"
src="https://github.com/user-attachments/assets/6e3bf268-4af5-49a0-ae54-64ef77643b97"
/>

**4. `/header?height=24106587` Request (Envoy Proxy)**
<img width="591" alt="Screenshot 2025-01-24 at 19 44 32"
src="https://github.com/user-attachments/assets/120a1b9e-96e1-463e-a2dd-d299e4ff59ce"
/>

**5. Hydrator Enabled for `cometbft`** 
<img width="548" alt="Screenshot 2025-01-24 at 19 24 47"
src="https://github.com/user-attachments/assets/16b8d700-3e33-43a4-a1b7-16dabbf0a398"
/>

### Changes:
- Adds `qos/cometbft` implementation. Built using same pattern as
`qos/evm` package, then modified.
- Updates `cmd/qos.go` and `config/service_qos.go` files to include
`cometbft`.

## Issue

- Description: Builds upon the work done in PR #145
- Issue:
[#{ISSUE_NUMBER}](#87)
- Discussion:
https://discord.com/channels/824324475256438814/1331712606330949764/1331744131097296993

## Type of change

Select one or more from the following:

- [x] New feature, functionality or library
- [ ] Bug fix
- [ ] Code health or cleanup
- [ ] Documentation
- [ ] Other (specify)

## Sanity Checklist

- [x] I have updated the GitHub Issue `assignees`, `reviewers`,
`labels`, `project`, `iteration` and `milestone`
- [ ] For docs, I have run `make docusaurus_start`
- [ ] For code, I have run `make test_all`
- [ ] For configurations, I have update the documentation
- [ ] I added TODOs where applicable

---------

Co-authored-by: Daniel Olshansky <olshansky.daniel@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Status: ✅ Done
Development

No branches or pull requests

2 participants