Skip to content

Commit fed5250

Browse files
committed
Add PR doc
Signed-off-by: linning <[email protected]>
1 parent 6768bd9 commit fed5250

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

prdoc/pr_7836.prdoc

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
title: '[frame-system] Introduce event segment to store multiple events under one key'
2+
3+
doc:
4+
- audience: [Runtime User, Runtime Dev]
5+
description: |-
6+
Introduce a runtime config item `EventSegmentSize` and a runtime storage
7+
`EventSegments` to replace `Events` to manage the runtime event in `frame-system`.
8+
9+
If `EventSegmentSize` is set to `()` or explicit `0`, the `EventSegments` is not used
10+
and the event is still stored in `Events` as it is. If `EventSegmentSize` is set to `> 0`,
11+
`EventSegments` is used instead of `Events`.
12+
13+
For runtime users, if you need to query the event through runtime storage directly
14+
(e.g. generate storage proof for a event) be aware to use `EventSegments` if it is
15+
activated.
16+
17+
For runtime developers, there is a storage migration `migrate_event_from_previous_block`
18+
that properly clean up the event from the previous block, do include this migration to
19+
the runtime whenever `EventSegmentSize` is changed.
20+
21+
crates:
22+
- name: frame-system
23+
bump: minor

0 commit comments

Comments
 (0)