Skip to content

Conversation

@ceyonur
Copy link
Collaborator

@ceyonur ceyonur commented Nov 18, 2024

Why this should be merged

getCurrentValidators in Platform VM API returns uptime percentage. This PR changes the uptime seconds to uptime percentage in GetCurrentValidators API to keep the consistency between APIs. It also adds NodeID filtering.

How this works

  • plugin/evm/client.go: Modified the GetCurrentValidators method to accept nodeIDs as a parameter, allowing for filtered queries. [1] [2]
  • plugin/evm/service.go: Introduced GetCurrentValidatorsRequest to handle node ID filtering and updated the GetCurrentValidators method to use this request. Additionally, changed the Uptime field to UptimePercentage for consistency with the PlatformVM API. [1] [2] [3]

Support for new method in state interfaces:

How this was tested

Locally

Need to be documented?

Yes

Need to update RELEASES.md?

Not since we have not captured the API.

@ceyonur ceyonur requested review from a team and darioush as code owners November 18, 2024 14:21
@ceyonur ceyonur merged commit 6083668 into master Nov 19, 2024
14 checks passed
@ceyonur ceyonur deleted the uptime-api-nits branch November 19, 2024 14:22
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