Adapted fork of radicale
Go to file
Unrud 9ceae0a751 Make Radicale fast (#569)
* Change get_multi to also return missing items

get_multi is not used anywhere and this makes it easier to use.

* Use get_multi for report requests

* Add get_all to BaseCollection

This can be used for optimization on multifilesystem.

* Use iterator for files

* Remove unnecessary checks

This never happens and would be an error.

* Don't raise exception when calling get with colliding name

This behavior is wrong, it should be handled as if the file doesn't exist.

* Use get_all and get_multi to skip unnecessary checks

Collision checks are slow on big collections.

* Use exception instead of existence checks

It's a bit faster.

* Use os.scandir instead of os.listdir

It's faster and doesn't load all files at once.

* Cache metadata when storage is read-only

Metadata is queried a lot during a request. It's quiet slow to load and parse the file every time.

* Cache the etag when the storage is read-only

The etag is calculated twice for GET requests on collections.

* Add helper method for cleaning caches

* Use item etags to calculate collection etag

It's very slow and unnecessary to parse all files with VObject and serialize them again.

* Cache serialized collections in file system

Serialization is very slow for big collections. This caches the result in a file.

* Add helper function for prefilters

The simplify_prefilters functions converts XML filters to a simple tag and time range, which can be easily matched against the tag and time range that are extracted from vobject_items by the function find_tag_and_time_range.

* Add ability to cache etag and serialization of item

Parsing items with vobject is very slow and not required for many requests.
Caching can be used to speed it up.

* Cache metadata and serialization from items in file system

Store the serialized text and the tag and time range from vobject_items in the cache.
The metadata is used for prefilters.

* Remove the cache for the serialization of collections

* Serialize calendars without vobject

Merge the calendar components manually. This is much faster and requires less memory. Caching of the result is not required anymore.

* Allow pre_filtered_list to indicate that filters match

The storage backend can indicate that it evaluated the filters completely.

* Skip filtering with vobject if prefiltering is sufficient

``simplify_prefilters`` indicates if the simplified condition is identical to ``filters``.
This is used in the multifilesystem backend to detect if prefiltering is sufficient.

* Make constants global

* Use generator expressions

* Only extract elements from inside of VCALENDAR

This is unnecessary at the moment, the text representation should never contain anything but VCALENDAR.

* Improve comments

* restore backward compatiblity

* Small improvements for fastbackend
2017-06-02 14:14:55 +02:00
bin Update copyright years 2017-05-27 17:28:07 +02:00
radicale Make Radicale fast (#569) 2017-06-02 14:14:55 +02:00
.gitignore Update and clean .gitignore 2017-02-26 15:50:02 +01:00
.travis.yml Add tests for Python 3.6 and on MacOS 2017-03-04 14:34:57 +01:00
config Merge pull request #565 from Unrud/synctoken 2017-06-02 13:01:54 +02:00
COPYING Adding package documentation files 2009-09-01 15:59:18 +02:00
Dockerfile Update Dockerfile 2016-06-29 18:45:35 +02:00
logging thread and level in simple log formatter 2016-09-04 11:47:27 +02:00
MANIFEST.in Remove useless SQL file 2016-04-10 02:09:20 +02:00
NEWS.rst Version 2.0.0 2017-05-27 18:10:46 +02:00
radicale.fcgi Fail when config file doesn't exist in WSGI and FCGI scripts 2017-06-01 12:26:33 +02:00
radicale.py Update copyright years 2017-05-27 17:28:07 +02:00
radicale.wsgi Fail when config file doesn't exist in WSGI and FCGI scripts 2017-06-01 12:26:33 +02:00
README Update README 2013-08-12 18:36:55 +02:00
README.rst Update README 2013-08-12 18:36:55 +02:00
rights Always match full username/collection with regex 2016-08-01 10:07:21 +02:00
setup.cfg Merge setup.cfg and pytest.ini, fix tests 2017-04-15 10:51:00 +02:00
setup.py Include files for web interface in package 2017-06-01 16:10:27 +02:00
TODO.rst Version 1.0 2015-09-14 11:49:34 +02:00

Radicale is a free and open-source CalDAV and CardDAV server.

For complete documentation, please visit the Radicale online documentation
(http://www.radicale.org/documentation).