1

There are likely reasons for this, but I'm not sure what they are yet.

In a parachain using pallet_session, is there a way for sudo/root/governance to force a session to rotate faster/cut a session short?

Reason for wanting to rotate (as there might be a better way to solve the issue): When using invulnerable collators, it can take a full session to remove collators that are failing. If there are several failing, then it can take even longer in real time as the block formation is slow.

1 Answer 1

0

The on_initialize hook of pallet-session checks ShouldEndSession::should_end_session() (ref). The ShouldEndSession is a configurable and can be implemented to your own needs.

A parachain created a pallet to be able to change the session duration: https://github.com/AcalaNetwork/Acala/blob/27a6d5ac1f7481bb4e16b1ea697db7b8e2210c8c/runtime/acala/src/lib.rs#L297-L299

You could implement something your own where you make it possible to abort a session. In other words, have the session rotate before the end of the duration.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.