Source

pyramid_perfstat / pyramid_perfstat / __init__.py

Diff from to

File pyramid_perfstat/__init__.py

 
 from pyramid_perfstat.utils import STATIC_PATH, ROUTE_PREFIX
 from pyramid_perfstat.perf_serializer import PerfDbManager
-from pyramid_perfstat.perf_serializer import new_perfstat_request_subscriber
-
 
 def to_int(*segment_names):
     def predicate(info, request):
 
         perf_manager = PerfDbManager(request)
         perf_manager.insert_data(time.time()-t0)
-        
         return result
     
     return perf_tween
     such as mean time, number of request urls etc ...
     """
     config.add_static_view(ROUTE_PREFIX+'/static', STATIC_PATH)
-    config.add_subscriber(new_perfstat_request_subscriber,NewRequest)
     
     config.add_tween('pyramid_perfstat.perf_tween_factory', under=EXCVIEW)
     config.include(include_perf_routes, route_prefix=ROUTE_PREFIX)
 
     # scan views
     config.scan('pyramid_perfstat.views')
+    config.scan('pyramid_perfstat.perf_serializer')