Follow ReferenceFields in EmbeddedDocuments with select_related
For the following structure:
    class Playlist(Document):
        items = ListField(EmbeddedDocumentField("PlaylistItem"))
    class PlaylistItem(EmbeddedDocument):
        song = ReferenceField("Song")
    class Song(Document):
        title = StringField()
this patch prevents the N+1 queries otherwise required to fetch all
the `Song` instances referenced by all the `PlaylistItem`s.
			
			
This commit is contained in:
		| @@ -6,6 +6,7 @@ Changelog | ||||
| Changes in 0.9.X - DEV | ||||
| ====================== | ||||
|  | ||||
| - Follow ReferenceFields in EmbeddedDocuments with select_related #690 | ||||
| - Added preliminary support for text indexes #680 | ||||
| - Added `elemMatch` operator as well - `match` is too obscure #653 | ||||
| - Added support for progressive JPEG #486 #548 | ||||
|   | ||||
		Reference in New Issue
	
	Block a user