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

Penciller Memory and slicing binaries #285

Closed
martinsumner opened this issue Jun 14, 2019 · 2 comments
Closed

Penciller Memory and slicing binaries #285

martinsumner opened this issue Jun 14, 2019 · 2 comments

Comments

@martinsumner
Copy link
Owner

The metadata for a riak object is directly extracted from the binary version of the riak object.

However, this is may mean that when the metadata is being held in the Penciller, it might have a reference to a shadow of the old object.

If, for example 10K 2MB objects are added (with 1KB metadata per object). When those 10K objects are in the penciller's memory, the penciller will have 10MB of binary data referenced - however, the reference is to part of a bigger binary, and although the rest of the bigger binary is not referenced, the whole of the bigger binary cannot be GC'd. Therefore, in effect the penciller has references to 20GB of binary heap memory.

@martinsumner
Copy link
Owner Author

#286

@martinsumner
Copy link
Owner Author

This is resolved by forcing a binary copy in the case where a section of the main object is binary is extracted to be the binary metadata.

Volume tests reveal a small improvement in throughput, and a reduction in the memory overhead of running Riak/leveled even when not bombarding Riak with large objects.

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

No branches or pull requests

1 participant