[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [tor-bugs] #10697 [Tor Weather]: Fetch hourly lists from Onionoo with relay status



#10697: Fetch hourly lists from Onionoo with relay status
-----------------------------+-------------------------------------
     Reporter:  baumanno     |      Owner:  baumanno
         Type:  task         |     Status:  assigned
     Priority:  normal       |  Milestone:
    Component:  Tor Weather  |    Version:
   Resolution:               |   Keywords:  weather-rewrite, hourly
Actual Points:               |  Parent ID:
       Points:               |
-----------------------------+-------------------------------------

Comment (by baumanno):

 Caching-logic has been implemented, based around the response-code
 returned by the request to Onionoo.
 There are two possible cases:

 1. 200 OK : store the (subset of the) details document along with the
 Last-Modified-header to database; Last-Modified will become If-Modified-
 Since in any subsequent requests
 2. 304 Not modified : work on the cached document (or do nothing at all)

 Please see https://github.com/baumanno/tor-weather-rewrite for code and
 feel free to comment!

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/10697#comment:5>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
_______________________________________________
tor-bugs mailing list
tor-bugs@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs