Refactor out GridFS functions into separate class.
Put GridFS-related stuff into a separate class.