Skip to content

Refactor Telos API endpoint settings to improve robustness #1950

@chuck-h

Description

@chuck-h

Background

The methods establishing endpoint URLs for blockchain http connections are confusing and fragile. API endpoints change over time, and most of the default values in the code are obsolete. The app relies on updated values from firebase remote config to replace these:
image
but connection_notifier is hard coded:
image
There are also a few hard-coded hypha.earth urls sprinkled around, not sure how many of them are dead.

There was a period of time when the telos.mainnet.net load-balancing endpoint was working well for us, but in Spring 2024 they put a rate limiter on it that locks us out during the burst of API calls at wallet startup. We will need to go back to finding our own public api providers (or eventually paid providers depending on how things scale and evolve).

Suggestion
API access should be refactored to have a single mechanism for reaching the Telos api that doesn't rely on telos.mainnet.net. When we get network errors we should use something like the connection_notifier code to pick a live endpoint from a list. The whole list should be updated from firebase remote config. (Also might access https://telos.antelope.tools/endpoints ).
ref https://github.com/JoinSEEDS/seeds_light_wallet/blob/master/lib/screens/app/interactor/viewmodels/connection_notifier.dart

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions