Implemented the size method in GridFS storage, updated docs

This commit is contained in:
Roberto Rosario
2011-03-04 02:49:23 -04:00
parent 9674d4d3ee
commit 30c6292630
4 changed files with 22 additions and 9 deletions

View File

@@ -27,7 +27,7 @@ Features
* Multilingual (English, Spanish)
* Duplicated document search
* Upload multiple documents inside a ZIP file
* Plugable storage backend (File based and GridFS included)
Requirements
---
@@ -40,6 +40,10 @@ Python:
* django-celery
* celery
For the GridFS storage backend:
* PyMongo
* GridFS
Or execute pip install -r requirements/production.txt to install the dependencies automatically.
Executables:
@@ -48,7 +52,7 @@ Executables:
* libmagic
* tesseract-ocr - An OCR Engine that was developed at HP Labs between 1985 and 1995... and now at Google.
* unpaper - post-processing scanned and photocopied book pages
* MongoDB
License
-------

View File

@@ -71,8 +71,7 @@ class GridFSStorage(Storage):
def size(self, name):
#TODO: Implement
return 0
return self.fs.get_last_version(name).length
def move(self, old_file_name, name, chunk_size=1024*64):

View File

@@ -93,9 +93,18 @@ favicon
http://www.iconfinder.com/icondetails/21581/24/draw_pyramid_icon
by Gnome Project
MongoDB
MongoDB - (from "humongous") is a scalable, high-performance, open
source, document-oriented database.
Copyright 10gen
http://www.mongodb.org/
PyMongo
PyMongo - is a Python distribution containing tools for working with
MongoDB, and is the recommended way to work with MongoDB from
Python.
GridFS
Copyright 2009, Michael Dirolf
http://api.mongodb.org/python/
GridFS - is a storage specification for large objects in MongoDB
Copyright 10gen
http://www.mongodb.org/display/DOCS/GridFS+Specification

View File

@@ -51,3 +51,4 @@
2011-Mar 04
* Initial GridFS storage support
* Implemented size and delete methods for GridFS