summaryrefslogtreecommitdiffstats
path: root/main/models.py
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2014-10-19 14:19:05 -0500
committerDan McGee <dan@archlinux.org>2014-10-19 14:19:05 -0500
commit1ff2e37e049004852681794537417a1947bf6f18 (patch)
tree09ab371e9c0d8a4067ac04ea5715ae53ac2ae2b3 /main/models.py
parent7c26f6b7a4d29faede58d2feb13ef961e4725637 (diff)
downloadarchweb-1ff2e37e049004852681794537417a1947bf6f18.tar.gz
archweb-1ff2e37e049004852681794537417a1947bf6f18.zip
Simplify last modified and etags processing for feeds
We had this elaborate system set up with caching and invalidation, which is overkill since we cache the result of the view anyway. Just hit the database when needed to find the last change to the respective model class and be done with it. Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'main/models.py')
-rw-r--r--main/models.py6
1 files changed, 1 insertions, 5 deletions
diff --git a/main/models.py b/main/models.py
index 09b1adc0..1b95f3fa 100644
--- a/main/models.py
+++ b/main/models.py
@@ -443,12 +443,8 @@ class PackageFile(models.Model):
db_table = 'package_files'
-# connect signals needed to keep cache in line with reality
-from main.utils import refresh_latest
-from django.db.models.signals import pre_save, post_save
+from django.db.models.signals import pre_save
-post_save.connect(refresh_latest, sender=Package,
- dispatch_uid="main.models")
# note: reporead sets the 'created' field on Package objects, so no signal
# listener is set up here to do so
pre_save.connect(set_created_field, sender=Donor,