Permalink
Browse files

better names for scheduler stats

  • Loading branch information...
1 parent 263e302 commit 8b4842055903ca3218e8e19b4669790921274872 @pablohoffman pablohoffman committed Sep 13, 2012
Showing with 4 additions and 4 deletions.
  1. +4 −4 scrapy/core/scheduler.py
View
@@ -49,20 +49,20 @@ def enqueue_request(self, request):
return
dqok = self._dqpush(request)
if dqok:
- self.stats.inc_value('scheduler/disk_enqueued', spider=self.spider)
+ self.stats.inc_value('scheduler/enqueued/disk', spider=self.spider)
else:
self._mqpush(request)
- self.stats.inc_value('scheduler/memory_enqueued', spider=self.spider)
+ self.stats.inc_value('scheduler/enqueued/memory', spider=self.spider)
self.stats.inc_value('scheduler/enqueued', spider=self.spider)
def next_request(self):
request = self.mqs.pop()
if request:
- self.stats.inc_value('scheduler/memory_dequeued', spider=self.spider)
+ self.stats.inc_value('scheduler/dequeued/memory', spider=self.spider)
else:
request = self._dqpop()
if request:
- self.stats.inc_value('scheduler/disk_dequeued', spider=self.spider)
+ self.stats.inc_value('scheduler/dequeued/disk', spider=self.spider)
if request:
self.stats.inc_value('scheduler/dequeued', spider=self.spider)
return request

0 comments on commit 8b48420

Please sign in to comment.