-
Notifications
You must be signed in to change notification settings - Fork 701
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
rpc server: listen to ipv6 socket
if available and --experimental-rpc-endpoint
CLI option
#4792
Conversation
…support-ipv6-sockets
ipv6 by default
and --rpc-listen-addrs
This is definitely very useful for multiple use cases and it is a feature that has been lacking for:
|
This format for allowing options to be passed with multiple listen addrs looks good to me! |
Very useful feature. One remark: can we avoid using whitespace in the arguments? It sometimes causes issues. Ideally, allow specifying multiple |
Yeah, it should work without whitespaces but I can add a test for it. |
ipv6 socket
if available and --rpc-endpoint
CLI optionipv6 socket
if available and --experimental-rpc-endpoint
CLI option
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Nice job here 🙏
* master: (39 commits) short-term fix for para inherent weight overestimation (#5082) CI: Add backporting bot (#4795) Fix benchmark failures when using `insecure_zero_ed` flag (#5354) Command bot GHA v2 - /cmd <cmd> (#5457) Remove pallet::getter usage from treasury (#4962) Bump blake2b_simd from 1.0.1 to 1.0.2 (#5404) Bump rustversion from 1.0.14 to 1.0.17 (#5405) Bridge zombienet tests: remove old command (#5434) polkadot-parachain: Add omni-node variant with u64 block number (#5269) Refactor verbose test (#5506) Use umbrella crate for minimal template (#5155) IBP Coretime Polkadot bootnodes (#5499) rpc server: listen to `ipv6 socket` if available and `--experimental-rpc-endpoint` CLI option (#4792) Update approval-voting-regression-bench (#5504) change try-runtime rpc domains (#5443) polkadot-parachain-bin: Remove contracts parachain (#5471) Add feature to allow Aura collator to use full PoV size (#5393) Adding stkd bootnodes (#5470) Make `PendingConfigs` storage item public (#5467) frame-omni-bencher maintenance (#5466) ...
Close #5677 I made a nit when I moved this code: https://github.com/paritytech/polkadot-sdk/blob/v1.14.0-rc1/substrate/client/service/src/lib.rs#L379-#L385 in #4792 Thus: - (ip.is_loopback(), RpcMethods::Auto) -> allow unsafe - (!ip.is_loopback(), RpcMethods::Auto) -> deny unsafe --------- Co-authored-by: ggwpez <ggwpez@users.noreply.github.com>
Close #5677 I made a nit when I moved this code: https://github.com/paritytech/polkadot-sdk/blob/v1.14.0-rc1/substrate/client/service/src/lib.rs#L379-#L385 in #4792 Thus: - (ip.is_loopback(), RpcMethods::Auto) -> allow unsafe - (!ip.is_loopback(), RpcMethods::Auto) -> deny unsafe --------- Co-authored-by: ggwpez <ggwpez@users.noreply.github.com>
.custom_tokio_runtime(cfg.tokio_handle.clone()) | ||
.set_id_provider(RandomStringIdProvider::new(16)); | ||
|
||
if let Some(provider) = id_provider2.take() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hello @niklasad1, Thank you for this contribution. I've a question about this change.
Why are we using .take()
here. in the previous version this was not needed.
Close #3488, #4331
This changes/adds the following:
--experimental-rpc-endpoint
which allow to configure arbitrary listen addresses including the port, if this is enabled no other interfaces are enabled.So for instance in this PR it's now possible to start up three RPC endpoints as follows:
Needs to be addressed
1. Support binding to a random port if it's fails with the default stuff for backward compatible reasons2. How to sync that the rpc CLI params and that the rpc-listen-addr align, hard to maintain...3. Add similar warning prints for exposing unsafe methods on external interfaces..4. Inline todos + the hacky String conversion from rpc params.Cons with this PR
Manual strings parsing impl more error-prone than relying on clap....
//cc @jsdw @BulatSaif @PierreBesson @bkchr