archethic-node icon indicating copy to clipboard operation
archethic-node copied to clipboard

Improve DB field name

Open Neylix opened this issue 4 months ago • 0 comments

Is your feature request related to a problem?

Transaction in DB is stored with all field indexed by there name. This allow to read a transaction from DB only with the needed fields. But currently those fields are simply named using string like "validation_stamp.ledger_operations.transaction_movements". This is easier to read, but it takes a lot of space. Only the field names represent 575 bytes, and for 1M transaction it represent 548 Mo only for field name indexation.

Describe the solution you'd like

We could create a map to link field name with an integer, and write this integer in the file instead of the full field name. This would greatly reduce the size of a stored transaction

Additional context

No response

Epic

No response

Neylix avatar Sep 30 '24 09:09 Neylix