Skip to content

Leave reading the IO to Mongo::Grid #11

Merged
merged 2 commits into from Jul 29, 2011

2 participants

@sirlantis

Closes #10.

Mongo::Grid reads IOs chunkwise to avoid unnecessary memory usage. Is there a particular reason why save_attachments rewinds and reads the io into memory?

See: https://github.com/jnunemaker/joint/blob/master/lib/joint/instance_methods.rb#L22

Had to binmode fixtures first to get the tests pass on my machine.

@bkeepers bkeepers merged commit b8b1175 into jnunemaker:master Jul 29, 2011
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.