Merge lp://staging/~beuno/txstatsd/distinct-plugin-webstats into lp://staging/~txstatsd-dev/txstatsd/distinct-plugin
Proposed by
Martin Albisetti
Status: | Merged |
---|---|
Approved by: | Sidnei da Silva |
Approved revision: | 13 |
Merged at revision: | 11 |
Proposed branch: | lp://staging/~beuno/txstatsd/distinct-plugin-webstats |
Merge into: | lp://staging/~txstatsd-dev/txstatsd/distinct-plugin |
Diff against target: |
307 lines (+214/-2) 2 files modified
distinctdb/distinctmetric.py (+74/-1) distinctdb/tests/test_distinct.py (+140/-1) |
To merge this branch: | bzr merge lp://staging/~beuno/txstatsd/distinct-plugin-webstats |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Sidnei da Silva | Approve | ||
Review via email:
|
Commit message
Get distinct user stats.
Description of the change
Get distinct user stats.
To post a comment you must log in.
1- theres no need to keep all the attributes of DistinctMetricR eporter on DistinctResource Resource. __init_ _(self) bucket_ size
20 + def __init__(self, reporter):
21 + resource.
22 + self.reporter = reporter
23 + self.dsn = reporter.dsn
24 + self.prefix = reporter.prefix
25 + self.name = reporter.name
26 + self.bucket_size = reporter.
2- t1 and t2 both fall in the same bucket! (its only ten seconds difference)
3- you should also exercise the distinct part of the query, adding a repeated value in the bucket making sure it wont add to the count