Commit 1bf3f26
apollo_storage: add transaction_events table for event storage (#13461)
* apollo_storage: add transaction_events table for event storage
Events are now written to a dedicated transaction_events table in addition
to the events index table. Event iterators read from the new table instead
of deserializing transaction outputs from mmap files. This eliminates
redundant file I/O during event iteration and prepares for separating
events from TransactionOutput in a follow-up change.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* apollo_storage: store events in mmap file instead of MDBX
The transaction_events table now stores LocationInFile pointers into a
dedicated events.dat mmap file, rather than serializing Vec<Event>
directly into MDBX. This matches the pattern used for transaction outputs
and avoids MDBX size overhead for large event payloads.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>1 parent f533c54 commit 1bf3f26
8 files changed
Lines changed: 345 additions & 136 deletions
File tree
- crates
- apollo_reverts/src
- apollo_storage/src
- body
- db
- serialization
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
127 | 127 | | |
128 | 128 | | |
129 | 129 | | |
| 130 | + | |
| 131 | + | |
130 | 132 | | |
131 | 133 | | |
132 | 134 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
215 | 215 | | |
216 | 216 | | |
217 | 217 | | |
218 | | - | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
219 | 228 | | |
220 | 229 | | |
221 | 230 | | |
| |||
236 | 245 | | |
237 | 246 | | |
238 | 247 | | |
239 | | - | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
240 | 258 | | |
241 | 259 | | |
242 | 260 | | |
| |||
266 | 284 | | |
267 | 285 | | |
268 | 286 | | |
269 | | - | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
270 | 297 | | |
271 | 298 | | |
272 | 299 | | |
| |||
335 | 362 | | |
336 | 363 | | |
337 | 364 | | |
338 | | - | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
| 372 | + | |
| 373 | + | |
| 374 | + | |
339 | 375 | | |
340 | 376 | | |
341 | 377 | | |
| |||
0 commit comments