[tor-bugs] #24621 [Metrics/CollecTor]: Exclude lastModifiedMillis in index.json
Tor Bug Tracker & Wiki
blackhole at torproject.org
Thu Dec 14 09:12:05 UTC 2017
#24621: Exclude lastModifiedMillis in index.json
-----------------------------------+--------------------------
Reporter: karsten | Owner: metrics-team
Type: defect | Status: new
Priority: Medium | Milestone:
Component: Metrics/CollecTor | Version:
Severity: Normal | Keywords:
Actual Points: | Parent ID:
Points: | Reviewer:
Sponsor: |
-----------------------------------+--------------------------
I noticed that we're including a `lastModifiedMillis` field in the
`index.json` produced by CollecTor. Here's a local example:
{{{
{
"index_created": "2017-12-14 08:43",
"build_revision": "56a303e",
"path": "https://collector.torproject.org",
"directories": [
{
"path": "recent",
"directories": [
{
"path": "bridge-descriptors",
"directories": [
{
"path": "extra-infos",
"files": [
{
"path": "2017-10-25-18-30-02-extra-infos",
"size": 12059081,
"last_modified": "2017-10-25 18:30",
"lastModifiedMillis": 0 <--------------------
}
]
},
}}}
The reason is that we're using our own `Gson` instance in CollecTor, and
we need to specifically say that we want it to exclude fields without the
@Expose annotation. Let's do that. Trivial patch follows.
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/24621>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
More information about the tor-bugs
mailing list