diff Mapping.py @ 54:b535bce50626

the relationship between feed and its entries can be mapped as lazy -> fewer DB round trips
author Dirk Olmes <dirk@xanthippe.ping.de>
date Tue, 18 May 2010 03:12:00 +0200
parents a8442c3487b5
children 525a52169f60
line wrap: on
line diff
--- a/Mapping.py	Tue May 18 02:58:31 2010 +0200
+++ b/Mapping.py	Tue May 18 03:12:00 2010 +0200
@@ -62,7 +62,7 @@
     mapper(FeedEntry, feedEntryTable)
     mapper(Feed, feedTable,
         properties = {
-            "entries" : relation(FeedEntry, backref="feed")
+            "entries" : relation(FeedEntry, backref="feed", lazy=True)
         }
     )
     mapper(Preference, preferencesTable)