Zhen Ye 61b6ca5b73
enhance: add in mem shard manager (#41749)
issue: #41544

- Implement in-memory shard manager to maintain the shard state at write
ahead.
- Remove all rpc and meta operation at write ahead, make the segment
assignment logic only use wal and memory.
- Refactor global stats management, add node-level flush policy.
- Fix the recovery storage inconsistency bug when graceful close.

Signed-off-by: chyezh <chyezh@outlook.com>
2025-05-13 12:04:56 +08:00

12 lines
242 B
Go

package shards
type TxnManager interface {
RecoverDone() <-chan struct{}
}
// TxnSession is a session interface
type TxnSession interface {
// should be called when the session is done.
RegisterCleanup(cleanup func(), timetick uint64)
}