Skip to content

Potential Side Effects of Reusing Iterators vs. Creating New Instances? #13541

Open
@marks-yag

Description

@marks-yag

In my application scenario, I heavily rely on Iterator.SeekForPrev() for data retrieval. I've found that reusing the Iterator (via thread-local storage and performing Refresh before and after each use) improves performance by 10% to 80% compared to creating a new Iterator object each time.

I would like to ask what additional side effects might arise from reusing the Iterator handle compared to creating a new one each time?

Thand you!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions