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

Refactor: Cleanup related to blue/green versions support [NONEVM-1114] #486

Merged
merged 8 commits into from
Jan 27, 2025

Conversation

toblich
Copy link
Contributor

@toblich toblich commented Jan 22, 2025

Continues with refactor started in #414, #418, #432, #437, #442 & #454

This PR does a few unrelated small fixes here and there, I recommend reviewers look at it commit-by-commit. I've made each commit its own fix, with a one-liner title explaining the idea.

However, here's the list of changes with some additional info:

  • Adds the config account to all methods that did not have them. This will allow us to configure the routing layer in each method, so we can do blue/green upgrades and shift traffic between versions. ⚠️ This is an interface change
  • Removes internal error from the IDL by restricting its visibility. Similar to what was done in Refactor: Visibility changes for internal structs & move code around [NONEVM-1114] #454, just for another error.
  • Removes code in the versioned-module tests that was implementing a method on TimestampedPackedU224, as that is an interface struct for us (meaning users have to send it in) so it's not versioned, and that could have leaked its implementation across versions. It was dead code anyway, so it was easy to remove.
  • The MAX_ORACLES constant was already explicitly added to the IDL, so I moved it out of the versioned module, as it is thus part of our interface.
  • There were some imports in the versioned module that were getting versioned module via use crate::v1::..., thus making it break if we ever copy-paste that into a v2 module. Now, they just use super::..., making it explicitly contained within their own module even if we copy-paste.

@toblich toblich requested a review from a team as a code owner January 22, 2025 19:02
Copy link

Metric refactor/things main
Coverage 76.4% 76.3%

@toblich toblich merged commit 5f86ab6 into main Jan 27, 2025
17 checks passed
@toblich toblich deleted the refactor/things branch January 27, 2025 15:33
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.

2 participants