Skip to content

Caching data spends a lot time on marshaling/unmarshaling data. #35

Description

@tok-kkk

Currently, the cacher of lightnode is using a TTL table of kv. It will marshal/unmarshal when write/read the response. Since the response can be really big, marshal/unmarshal is really expensive in this case.

For a queryBlocks request, the response can be 6- 10MB. A single read/write will take 0.2-0.3 seconds.

The best best solution I can think of is to have a TTL implementation of the bounded map which don't do marshaling/unmarshaling when wirte/read.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions