-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Conversation
We are supporting muliple polkadot-like chains and all have different client types. This pr reworks the client handling by having all of them in one enum combined. Besides that, there is added a special trait `ExecuteWithClient` to use the internal client.
pub enum Client { | ||
Polkadot(Arc<crate::FullClient<polkadot_runtime::RuntimeApi, crate::PolkadotExecutor>>), | ||
Westend(Arc<crate::FullClient<westend_runtime::RuntimeApi, crate::WestendExecutor>>), | ||
Kusama(Arc<crate::FullClient<kusama_runtime::RuntimeApi, crate::KusamaExecutor>>), |
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.
Will you add a Rococo variant here?
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.
Yeah, the pr was not yet merged :)
@@ -52,7 +52,7 @@ pub use polkadot_runtime; | |||
pub use kusama_runtime; | |||
pub use westend_runtime; | |||
use prometheus_endpoint::Registry; | |||
pub use self::client::PolkadotClient; | |||
pub use self::client::*; |
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.
it would be better to explicitly export. glob re-exports scare me :)
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.
Generally looks OK. I'm not sure what we will do about service-new
- won't we want the same thing there?
Co-authored-by: Robert Habermeier <rphmeier@gmail.com>
* master: Unalias Substrate Imports (#1530) Rewrite client handling (#1531) Integrate ChainApi with all messages (#1533) Add Rococo test network (#1363) Fix a typo parathreads -> parachains (#1529) Cleanup upcoming paras (#1527) Sudo wrapper for paras (#1517) Implementer's guide: notes on contextual execution (#1525) Companion for substrate/6782 (#1523) Sort out validation errors (#1516)
We are supporting muliple polkadot-like chains and all have different
client types. This pr reworks the client handling by having all of them
in one enum combined. Besides that, there is added a special trait
ExecuteWithClient
to use the internal client.