Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Assign sequential object IDs at Max export time #1425

Merged
merged 2 commits into from
Sep 6, 2023

Conversation

dpogue
Copy link
Member

@dpogue dpogue commented Jul 15, 2023

No description provided.

@Hoikas
Copy link
Member

Hoikas commented Jul 16, 2023

So, it occurs to me that this has the same problem that libhsplasma had previously. What's happening here is that a PRP's ObjIDs are being sorted, then the PRP is written. Then, the next PRP's ObjIDs are sorted and the PRP is written. So, any cross-page references between PRPs may be shattered due to wrong ObjIDs being written if a reference is written out to another PRP before the other PRP is sorted. Therefore, the PrepForWrite function needs to be called on all RegistryPageNodes before any PRP is written.

@Hoikas Hoikas self-requested a review July 16, 2023 18:36
@dpogue
Copy link
Member Author

dpogue commented Jul 16, 2023

@Hoikas I had the same thought... except that this appears to be consistent with the behaviour from before #264 was merged 🤷🏼‍♂️

@Hoikas
Copy link
Member

Hoikas commented Jul 16, 2023

Let's go ahead and preemptively fix that problem so we don't have any land mines waiting on us. Cyan tended to be pretty good about limiting themselves one or two PRPs per max file, but we need to be more resilient due to not being on the other side of the hallway from our users 😉

@dpogue dpogue marked this pull request as draft July 17, 2023 21:54
Co-Authored-By: Adam Johnson <AdamJohnso@gmail.com>
@dpogue
Copy link
Member Author

dpogue commented Sep 3, 2023

I exported the Nexus max files with this, and it appears that all the Object IDs are sequential.

@dpogue dpogue marked this pull request as ready for review September 3, 2023 22:54
Co-Authored-By: Adam Johnson <AdamJohnso@gmail.com>
@Hoikas Hoikas merged commit dc4df39 into H-uru:master Sep 6, 2023
14 checks passed
@dpogue dpogue deleted the keyring-ordering branch September 8, 2023 21:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants