-
Notifications
You must be signed in to change notification settings - Fork 362
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
Streamline config shapes (rust) #2215
Comments
See #2491 for the Typescript-level changes of this workstream |
### Description When I was working on #2215 I noticed that we are not using either zipkin or jaeger at all and possibly never have. Ripping these out to reduce dead code and also simplify our package dependencies. ### Drive-by changes None ### Related issues Discovered through #2215 ### Backward compatibility Yes - we were not using these features and did not document their existence ### Testing Manual - Verified that when running deploy-agents, the generated configs do not have jaeger or zipkin enabled on `main` and then tested to make sure they still work in this branch
Relates to #1865 |
Draft PR to track progress |
### Description Updates the typescript definitions based on the rust code. This is the first in a series of PRs for handling Rust config streamlining. ### Drive-by changes - A couple of the core types I refined, please validate the definitions. ### Related issues Progress on #2215 Relates to #2491 ### Backward compatibility Yes ### Testing Unit Tests
### Description This is a fix for an issue in the arguments and environment where we are unable to correctly support attribute names due to the casing. The main issue cannot be fully fixed practically by this PR because it would cause some configuration cases to break. For now it adds manual exceptions for the command line argument case and leaves envs as they were. There are then two new parsers that can be used with the new config format. ### Drive-by changes Also adds this to argument parser since it was trivial to copy/paste it and it will allow us to harden parsing when we switch over. ### Related issues - Fixes #2662 - Fixes #2663 - Progress on #2215 ### Backward compatibility Yes ### Testing Unit Tests
High-level rollout plan proposals:
(1) is the easiest but (3) is pretty easy. (2) might be finicky. |
### Description This is a big one for #2215... 1. Splits the parsing of configs from the config definitions to support both the old, new, and future parsers simultaneously. (We might want to rename it from parser to config format or something; not set on this name). 2. Implements the new config format without switching to it or enabling it. This means this PR does introduce dead code that is going to be used in the next PR. ### Drive-by changes - Deleted some unused (or single use) macros defined in hyperlane base - Updated the definition of the config parsing trait to simplify implementation - Added some more ergonomic methods of handling errors in config parsing - Removed any raw `unwrap()` I noticed since these cause difficult to debug errors in prod. - Added some additional validation to catch code mistakes in config path definitions ### Related issues - Progress on #2215 - Comes after #2658 ### Backward compatibility Yes ### Testing Manual (E2E only for now to make sure I did not break the old config format)
### Description This does two things: 1) It parses the agent-specific configs for the relayer, validator, and scraper. 2) It removes the rigid structures that had been in place for parsing that were called out earlier and instead parses the serde json values directly. This PR does not cut over to the new versions just yet. That can happen once we start integrating it into the testing and deployment pipelines. ### Drive-by changes - Derive more was added and used where it made sense - The old config macro was removed ### Related issues - Progress on #2215 ### Backward compatibility Yes ### Testing None
This will be kept up to date with main, and then after v3 is merged, we will go ahead and merge this in before we release. |
@tkporter to review helm charts portion, dan has done his review |
@mattiecnvr is #2659 the PR that we will merge into v3? |
### Description Continues the updates to the rust config shapes by updating deployment and runtime expectations. This PR also attempts to rely on the new single source of truth created by the schema in the SDK as much as reasonably possible which helped delete more code but also give some guarantees of consistency. THIS IS A BREAKING CHANGE! It changes the config shapes the agents want and we should not merge this until we are ready. Fixes #2215 --------- Co-authored-by: Guillaume Bouvignies <guillaumebouvignies@gmail.com> Co-authored-by: Yorke Rhodes <yorke@hyperlane.xyz> Co-authored-by: Guillaume Bouvignies <guillaume.bouvignies@kurtosistech.com>
Continues the updates to the rust config shapes by updating deployment and runtime expectations. This PR also attempts to rely on the new single source of truth created by the schema in the SDK as much as reasonably possible which helped delete more code but also give some guarantees of consistency. THIS IS A BREAKING CHANGE! It changes the config shapes the agents want and we should not merge this until we are ready. Fixes #2215 --------- Co-authored-by: Guillaume Bouvignies <guillaumebouvignies@gmail.com> Co-authored-by: Yorke Rhodes <yorke@hyperlane.xyz> Co-authored-by: Guillaume Bouvignies <guillaume.bouvignies@kurtosistech.com>
This is the sister ticket to #2214 . It streamlines the existing chain config with the typescript one as they are so close to each other already. In addition to that streamlining benefit, it also captures the following benefits:
ChainMetadata
), which would potentially reduce one more argument to need to be specified via ENV vars to get startedrpcConsensusType
apart fromconnection
and makes it easier to specify different defaults per agent type (i.e. fallback for relayer and scraper, quorum for validator) and thus obsoletes https://github.com/hyperlane-xyz/issues/issues/438Subissues
finality_blocks
instead ofreorg_period
in validator #532Tasks
PRs
The text was updated successfully, but these errors were encountered: