-
Notifications
You must be signed in to change notification settings - Fork 126
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
connect grandpa rpc #302
connect grandpa rpc #302
Conversation
The PR looks good to me, the grandpa rpc is supported. |
Box::new(move |deny_unsafe, subscription_executor: sc_rpc::SubscriptionTaskExecutor| { | ||
let deps = | ||
crate::rpc::FullDeps { | ||
client: client.clone(), | ||
pool: pool.clone(), | ||
deny_unsafe, | ||
grandpa: crate::rpc::GrandpaDeps { | ||
shared_voter_state: shared_voter_state.clone(), | ||
shared_authority_set: shared_authority_set.clone(), | ||
justification_stream: justification_stream.clone(), | ||
subscription_executor: subscription_executor.clone(), | ||
finality_provider: finality_proof_provider.clone(), | ||
}, | ||
backend: rpc_backend.clone(), | ||
}; | ||
crate::rpc::create_full(deps).map_err(Into::into) | ||
}) | ||
}; |
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.
lot of boxing and cloning here, I wonder if it is actually all necessary?
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.
I just checked, all clones are needed. can't fully understand the grammar yet, like need a new variable then box can pin them
The pr is from MacieRaj, rebased with development branch.