Skip to content

Conversation

@taylor-steve
Copy link
Contributor

I'm chasing down some performance issues I'm seeing for some of our very large manifests. I noticed that it seems we pay the full price for each repeated key.camelize call. It might make sense to compute those once and re-use the saved value.

Using the fixture data in our Purl app for https://purl.stanford.edu/bc854fy5899 to get to the point where we can return the result of to_ordered_hash the the memory_profiler gem reports the following for this change:

"allocated memory by gem" for activesupport-8.0.2 drops from 120401765 to 44878373
"allocated objects by gem" for activesupport-8.0.2 drops from 1600601 to 606617

@taylor-steve taylor-steve marked this pull request as ready for review November 5, 2025 21:24
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.

2 participants