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

Individual Network Config #582

Merged
merged 5 commits into from
Jun 18, 2024
Merged

Individual Network Config #582

merged 5 commits into from
Jun 18, 2024

Conversation

ScottyPoi
Copy link
Collaborator

Clients should be able to configure individual networks with unique radius settings.

However, all supported subnetworks are initialized using a global radius value.

This adds a type: NetworkConfig, and updates the type PortalNetworkOpts to accept as supportedNetworks a list of NetworkConfig options instead of simply a list of NetworkId. NetworkConfig includes NetworkId as well as a radius value.

PortalNetwork client code was updated to assign each network its unique radius value.

CLI and test scripts were updated to pass the new NetworkConfig list into client constructors.

export interface NetworkConfig {
  networkId: NetworkId
  radius: bigint
}

export interface PortalNetworkOpts {
  supportedNetworks?: NetworkConfig[]
  ...
}

@ScottyPoi
Copy link
Collaborator Author

will have to update ethereumjs/ethereumjs-monorepo#3444 if merged

@ScottyPoi ScottyPoi merged commit fd894fa into master Jun 18, 2024
4 checks passed
@holgerd77 holgerd77 deleted the radius-config branch June 19, 2024 06:51
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.

1 participant