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

[tor-bugs] #11577 [Onionoo]: Use Gson to format/parse documents rather than StringBuilder/Scanner



#11577: Use Gson to format/parse documents rather than StringBuilder/Scanner
-------------------------+-------------------------
 Reporter:  karsten      |          Owner:  karsten
     Type:  enhancement  |         Status:  new
 Priority:  normal       |      Milestone:
Component:  Onionoo      |        Version:
 Keywords:               |  Actual Points:
Parent ID:               |         Points:
-------------------------+-------------------------
 Except for unit tests, we're formatting and parsing JSON documents
 ourselves using classes like StringBuilder and Scanner.  This was the
 quickest way for me to produce a running prototype back in 2011, and it
 scaled surprisingly well.  But there are several reasons for finally
 switching to a JSON library: less code, fewer bugs, and potentially better
 performance.  The most recent hack for #11350 made me think that we
 finally have to switch to Gson for formatting and parsing all our JSON
 documents.

 The following classes should be (de-)serialized using Gson:
  - UptimeDocument
  - ClientsDocument
  - WeightsDocument
  - BandwidthDocument
  - DetailsDocument
  - DetailsStatus

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/11577>
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