diff piecrust/app.py @ 419:6801ad5aa1d4

internal: Optimize page segments rendering. * Don't create the page data up-front, since it's wasted work if the page has cached rendered segments. * Add a performance counter for data building.
author Ludovic Chabant <ludovic@chabant.com>
date Sat, 20 Jun 2015 23:25:38 -0700
parents 0e9a94b7fdfa
children 456db44dcc53
line wrap: on
line diff
--- a/piecrust/app.py	Sat Jun 20 23:24:17 2015 -0700
+++ b/piecrust/app.py	Sat Jun 20 23:25:38 2015 -0700
@@ -415,6 +415,7 @@
         self.env.initialize(self)
         self.env.registerTimer('SiteConfigLoad')
         self.env.registerTimer('PageLoad')
+        self.env.registerTimer("PageDataBuild")
 
     @cached_property
     def config(self):