Questions tagged [collectionfs]

CollectionFS is a suite of Meteor packages that together provide a complete file management solution including uploading, downloading, storage, synchronization, manipulation, and copying. It supports several storage adapters for saving to the local filesystem, GridFS, or S3, and additional storage adapters can be created.

CollectionFS is a suite of Meteor packages that together provide a complete file management solution including uploading, downloading, storage, synchronization, manipulation, and copying. It supports several storage adapters for saving to the local filesystem, GridFS, or S3, and additional storage adapters can be created.


The CollectionFS package makes available two important global variables: FS.File and FS.Collection.

  • An FS.File instance wraps a file and its data on the client or server. It is similar to the browser File object (and can be created from a File object), but it has additional properties and methods. Many of its methods are reactive when the instance is returned by a call to find or findOne.
  • An FS.Collection provides a collection in which information about files can be stored. It is backed by an underlying normal Mongo.Collection instance. Most collection methods, such as find and insert are available on the FS.Collection instance. If you need to call other collection methods such as _ensureIndex, you can call them directly on the underlying Mongo.Collection instance available through myFSCollection.files.

A document from a FS.Collection is represented as a FS.File.

CollectionFS also provides an HTTP upload package that has the necessary mechanisms to upload files, track upload progress reactively, and pause and resume uploads.

Read more in the documentation.

130 questions
0
votes
1 answer

What to `publish` when using CollectionFS with meteor

I'm trying to get the simplest example working with CollectionFS. So I started a new project meteor create test cd test meteor add cfs:standard-packages meteor add cfs:filesystem Now I add all the code from the README.md. In common.js…
gman
  • 100,619
  • 31
  • 269
  • 393
0
votes
1 answer

CollectionFS get url from Client

I am developing my first meteor app, and have just implemented uploading images using CollectionFS and gridfs. I can successfully view my uploaded images using but I need to access it from the client in Meteor. I am trying…
Cam
  • 13
  • 3
0
votes
0 answers

Getting file back from CollectionFS with Angular-Meteor

I'm pretty new with programming. I'm learning how to use CollectionFS with Angular, but cant get the files back from DB. Here is my code: Html:
0
votes
2 answers

How to overwrite DropzoneJS's XHR for GridFS?

I'm currently developping an image sharing plateform, using Meteor, CollectionFS and GridFS StorageAdapter. I'm also using the excellent package dbarrett:dropzonejs, but problem is its implementation for CollectionFS, especially regarding XHR and…
Sharlaan
  • 51
  • 9
0
votes
0 answers

Meteor CFS is limiting the Number of Files it's Displaying

I have no idea why it's doing it like this, but I'm using CollectionFS for Meteor, and I have an image uploader and on the page it's displaying the files that are uploaded and it's only displaying around 30 files at a time. I have no idea where this…
Omgabee
  • 97
  • 10
0
votes
3 answers

How to show correct profile picture Meteorjs

I am using CollectionFs to Upload profile pictures. Uploading and storing the image is successful. I can insert and show the image alright for one user but the problem is: For multiple users, when a user visit other users profiles, He sees his own…
Kaiyes
  • 33
  • 8
0
votes
0 answers

Meteor , collectionFS with cordova plugin ( org.apache.cordova.media )

here is the case, I wanna make an "whatsapp" like function of recording voice clip and save it in meteor apps using collectionFS. but it seems not support media object of cordova and show [Log] Uncaught Error: Error: DataMan constructor received…
Mike Wong
  • 43
  • 1
  • 5
0
votes
2 answers

Meteor - Access and Display Images

How would you access a folder full of images, get the url for each image and put it in an array, then {{each}} over that array to display each image on a page of my choosing? Everyone keeps saying CollectionFS, but for some reason, when I set it…
claytonzaugg
  • 55
  • 1
  • 9
0
votes
1 answer

Meteor 503 from CollectionFS

I got a 503 when trying to upload using the CollectionFS Filesystem adaptor (only on production, local works fine.) the response headers…
Matty H
  • 325
  • 4
  • 11
0
votes
2 answers

Reading files on the server with CollectionFS

I am trying to upload text files using the meteor package CollectionFS. They seem to be successfully loading on the client side. I cannot for the life of me figure out how to read the files. I have tried using .createReadStream and the node package…
0
votes
1 answer

How to get file url for specific store using collectionFS in meteor

How to get file url for specific store using collectionFS in meteor? I need to retrieve it in my onrendered code: var url = Images.findOne(filesList[index].id).url(); This return me default store for Images, but in Images i have two store: Images =…
Simone M
  • 677
  • 1
  • 10
  • 26
0
votes
1 answer

How to search over an FS Collection?

Anybody can help me out on this? I have a group of PDF documents that I would like to be able to search. I've attempted use matteodem:easy-search and meteorhacks:search-source, but both of them only handle Meteor Collections and not FS. I can get…
TheBetterJORT
  • 808
  • 9
  • 22
0
votes
1 answer

How are documents in CollectionFS able to store methods in MongoDB?

I'm using the Amazon S3 storage adapter with CollectionFS. Normally you can't store a method into MongoDB. For example, I can't have a document stored in my CustomerOrders collection with a method on it that modifies the document directly with a…
fuzzybabybunny
  • 5,146
  • 6
  • 32
  • 58
0
votes
1 answer

Meteor-CollectionFS gridfs images does not show

This is an attempt of uploading and displaying pictures using gridfs. This is placed on both server and client: var imageStore = new FS.Store.GridFS("images", {}); Images = new FS.Collection("images", { stores: [imageStore], filter: { …
Gravity123
  • 1,130
  • 3
  • 21
  • 39
0
votes
1 answer

Meteor data context with collectionFS

I want to get the fave.title within the collectionFS each block where I have "TITLE HERE", any ideas?