[tor-bugs] #9316 [BridgeDB]: BridgeDB should export statistics

Tor Bug Tracker & Wiki blackhole at torproject.org
Thu Oct 10 01:12:34 UTC 2013


#9316: BridgeDB should export statistics
--------------------------+-----------------------------
     Reporter:  asn       |      Owner:  isis
         Type:  task      |     Status:  needs_revision
     Priority:  normal    |  Milestone:
    Component:  BridgeDB  |    Version:
   Resolution:            |   Keywords:  metrics,bridges
Actual Points:            |  Parent ID:  #9199
       Points:            |
--------------------------+-----------------------------
Changes (by isis):

 * status:  assigned => needs_revision


Comment:

 Closing #9317 as a duplicate of this one, putting the information from
 that ticket on this one, and setting as 'needs revision' because I haven't
 testing or looked at this branch in a while.

 Quoting #9317:
 > While writing bridgedb's logger, I made a context manager for storing a
 state dictionary which is, so far rather loosely defined, but it would
 allow us to gather free statistics on bridgedb. Essentially, you would use
 it like so:
 > {{{
 > from bridgedb import log as logging
 > logging.callWithContext(myfoocontext, {'addBridgeAssignment':
 foobridge})
 > }}}
 > It is also safely threadable, so it would be possible to use this to
 retrieve debugging information from threads, for instance for #5232.
 >
 > The nice thing about this is that it is easily called from the logger
 (and will still handles log levels and all the other added features from
 #9199). The bad thing is that if it is not written very clearly, it could
 be difficult for other/new people reading the code to understand,
 especially if they are not familiar with Twisted.
 >
 > Part of this was also discussed between myself and Karsten on tor-
 assistants@…, earlier this month, in the "BridgeDB data for metrics"
 thread.
 >

-- 
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/9316#comment:4>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online


More information about the tor-bugs mailing list