Skip to content

Conversation

@nazar-pc
Copy link
Member

Finally we can do this.

Still can't remove sp-session dependency due to RPC layer requiring it (alongside with keystore which consensus chain doesn't have), I'm still thinking what to do about it without copy-pasting a bunch of non-trivial boilerplate.

Code contributor checklist:

@nazar-pc nazar-pc changed the title Custom spawn tasks Custom spawn_tasks Aug 14, 2024
@nazar-pc nazar-pc enabled auto-merge August 14, 2024 18:27
Copy link
Contributor

@shamil-gadelshin shamil-gadelshin left a comment

Choose a reason for hiding this comment

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

Do you mind adding context?

@nazar-pc
Copy link
Member Author

Context is basically in the second commit, PR description and partly in paritytech/polkadot-sdk#5364 mentioned in TODO

We don't need Substrate's prometheus server, we don't want its RPC server in some cases and we also don't want sp-session, though RPC is tightly coupled with it right now unfortunately. Once paritytech/polkadot-sdk#5364 is in our fork we'll no longer need to convert our full configuration data structure into Substrate's Configuration, which will make code simpler and more straightforward.

Copy link
Contributor

@shamil-gadelshin shamil-gadelshin left a comment

Choose a reason for hiding this comment

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

A small refactoring request - otherwise looks OK.

mod metrics;
pub(crate) mod mmr;
pub mod rpc;
mod spawn_tasks;
Copy link
Contributor

Choose a reason for hiding this comment

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

Consider changing to task_spawner: spawn_tasks::spawn_tasks looks awkward.

Copy link
Member Author

Choose a reason for hiding this comment

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

Renamed, though it is really a bad name in Substrate, I wouldn't call that function spawn_tasks in the first place.

@nazar-pc
Copy link
Member Author

One more thing: this finally allows us to customize informer, which we'll extend to show Subspace networking stats in addition to Substrate networking as well as various DSN sync stages, etc.

@nazar-pc nazar-pc added this pull request to the merge queue Aug 15, 2024
Merged via the queue into main with commit 72575a0 Aug 15, 2024
@nazar-pc nazar-pc deleted the custom-spawn_tasks branch August 15, 2024 12:26
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