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

feat!: Introduced --preset and clean up config #2859

Draft
wants to merge 14 commits into
base: master
Choose a base branch
from

Conversation

fryorcraken
Copy link
Collaborator

@fryorcraken fryorcraken commented Jun 28, 2024

Description

Breaking change: TWN config is applied when --preset=default is passed instead of --cluster-id=1.

Clean-up config by reducing the number of arguments and also aligning default config with waku-org/nwaku-compose.

Note for reviewers: commits are kept clean, hence review per commit may be preferred.

Changes

  • feat!: introduce preset option instead of deducing from cluster-id. cluster-id=1 still applies TWN config for now.
  • chore: remove unused import warning
  • feat: set keep-alive to true for default preset (TWN)
  • feat: set max connections to 150 by default
  • feat!: change default eth client value to empty string
  • feat: remove relay peer exchange
  • feat: remove agentString option
  • chore: reorder maxMessageSize as it is not RLN specific
  • doc: clarify max shard value on CLI args
  • validate RLN Relay config

@fryorcraken fryorcraken requested a review from a team June 28, 2024 11:37
Copy link

github-actions bot commented Jun 28, 2024

You can find the image built from this PR at

quay.io/wakuorg/nwaku-pr:2859

Built from c04988b

@fryorcraken fryorcraken changed the title doc: clarify max shard value on CLI args doc: clean up config Jun 28, 2024
@fryorcraken fryorcraken changed the title doc: clean up config feat!: clean up config Jun 28, 2024
Copy link
Contributor

@gabrielmer gabrielmer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks so much! I reaaaally like the changes!
The only thing I'm not sure about is removing Relay Peer Exchange.

I know Waku Peer Exchange and Discv5 are preferred, but it still works and is a valid discovery alternative

@jm-clius WDYT? Should it be removed?

# cluster-id=1 (aka The Waku Network)
of 1:
case confCopy.preset
of "default":
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To be more clear I would personally name the default "TWN" or something along those lines, but I'm ok too with "default"

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The reasoning behind it is to start my moving away from "the waku network" terminology.

@fryorcraken
Copy link
Collaborator Author

Updates description with a todo list.

@fryorcraken fryorcraken force-pushed the clean-config branch 4 times, most recently from 5489bd3 to 5a36061 Compare July 2, 2024 02:43
@fryorcraken fryorcraken changed the title feat!: clean up config feat!: Introduced --preset and clean up config Jul 2, 2024
@SionoiS
Copy link
Contributor

SionoiS commented Jul 2, 2024

LGTM so far except, max connection is too low because the actual number of connection is divided by a factor for peer management purposes. egg. incoming relay peers use 17% of total, service peers 30%, etc...

Having the actual numbers as config params could be done but is even more obscure params a good idea?

@fryorcraken
Copy link
Collaborator Author

LGTM so far except, max connection is too low because the actual number of connection is divided by a factor for peer management purposes. egg. incoming relay peers use 17% of total, service peers 30%, etc...

Having the actual numbers as config params could be done but is even more obscure params a good idea?

I think it's fine to keep a global parameter.

I used the default value from nwaku-compose. What value do you think should be set? I think we setup 300 in the fleets.

@fryorcraken fryorcraken force-pushed the clean-config branch 3 times, most recently from 12551d0 to 8998e46 Compare July 12, 2024 06:39
@SionoiS
Copy link
Contributor

SionoiS commented Jul 12, 2024

I used the default value from nwaku-compose. What value do you think should be set? I think we setup 300 in the fleets.

200 is a bit low I feel. 300 gives us ~15 in and 20 out replay peers last I remember.

@fryorcraken fryorcraken force-pushed the clean-config branch 2 times, most recently from ae7f07b to 72c2fca Compare July 15, 2024 03:06
@fryorcraken

This comment was marked as resolved.

@fryorcraken fryorcraken added the blocked This issue is blocked by some other work label Jul 15, 2024
@fryorcraken fryorcraken removed the blocked This issue is blocked by some other work label Aug 15, 2024
Not a protocol we want to use now.
Does not really make sense to have a default value set to localhost and
assume user has a local eth node running.
On the contrary, this can lead to issue where user doesn't understand
why the node tries to connect to localhost.
Similar value to nwaku-compose. `wakunode2` is assumed to be used as
service node by default.
To easily build and run wakunode2 from makefile.
Fails faster when ethereum client address is not passed.
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.

3 participants