-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: Extract registry types in to own crate (#453)
This PR extract the types exposed by the registry contract in to its own reusable crate: `registry_types`. This was done to avoid the duplication across our different service which; fetch the JSON, and then construct the Rust types. ## `registry_types` crate The registry types were already partially shared between Coordinator and the registry, but I've expanded on this to include all types rather than just a subset. I've created a new crate, rather than using the existing `./indexer/indexer_rule_type` crate as some packages needed to be upgraded, which caused conflicts across the `indexer/` cargo workspace - which seemed unnecessary to fix given that it is being deprecated. ## Registry contract updates `near-sdk` version `4.1.1` is no longer compilable because it depends on a non-existent crate, hence the upgrade to `5.0.0-alpha.1`. Since I was already making changes here, I decided to remove the migration related code as it is no longer needed. ## Consuming `registry_types` With the shared types in place, I've updated `block-streamer/` to use them, removing the existing types which it duplicates. I also went ahead and removed all types which were unused (left over from Alertexer). `indexer_rule_type` depends on `near-sdk` version `4.1.1` (the broken one), and since it's no longer shared, I removed that dependency so that it can compile again. Relates to #421
- Loading branch information
1 parent
663d4bc
commit af38be3
Showing
26 changed files
with
7,548 additions
and
1,978 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.