Hello,
You just have to manage it the same way you manage references between 2 "documents".
(oversimplistic example below)
members
{
_id : "user001",
name : "john doe"
files : [ "johnresume.doc" ]
}
// and you have save the document in gridfs :
GridFS gridfs = new GridFS(db, "downloads");
GridFSInputFile gfsFile = gridfs.createFile(file); << you binary content
gfsFile.setFilename("johnresume.doc");
gfsFile.save();
Like that you can find all the files for a members, so you manage the reference in your code.
You can also use some meta data in GridFS to extend with some custom attributes (setMetada() in Java)
Regards
Tug
@tgrall