Skip to content

The problem with method:calculateDataLength() #18

Open
@308twin

Description

I encountered a strange issue while testing inserts from k1000 to k1. When inserting in ascending order, the page management behaves normally, but when inserting in descending order, new pages are frequently requested. After conducting breakpoint testing, I believe the issue lies in the calculateDataLength method, particularly in this part of the code:

if (currentDataLen > 0) {
return currentDataLen;
}

When a page splits, the original page always uses the old value instead of recalculating. I understand that you implemented this to avoid repeated calculations, but it seems to have introduced some bugs.

Best regards.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions