Opened 7 years ago

Closed 7 years ago

#11516 closed defect (fixed)

Invalid dates in relays_published and bridges_published fields

Reported by: karsten Owned by: karsten
Priority: High Milestone:
Component: Metrics/Onionoo Version:
Severity: Keywords:
Cc: rndm Actual Points:
Parent ID: Points:
Reviewer: Sponsor:


There's a problem with dates in Onionoo's output:

{"relays_published":"9014-04-14 03:00:00",
"bridges_published":"14840-04-28 10:37:04",

Apparently this bug was introduced in the latest commit series from today. I still had the previous .war file around, and deploying that seemed to fix the issue. I don't know yet what the bug is.

Child Tickets

Change History (3)

comment:1 Changed 7 years ago by karsten

I couldn't find a bug, so I redeployed the new .war file. So far, works just fine. I wonder if the problem shows up after a certain time only. Set up a cronjob to fetch the summary file every ten minutes. Let's see.

comment:2 Changed 7 years ago by karsten

This was difficult to debug, but I think I found the bug: we're now using a single SimpleDateFormat instance per date pattern, but it turns out that SimpleDateFormat is not thread-safe. Changed to creating a new SimpleDateFormat instance for each usage and re-deployed. Let's see if this fixes the problem.

comment:3 Changed 7 years ago by karsten

Resolution: fixed
Status: newclosed

Fixed in df9abfe. Closing.

Note: See TracTickets for help on using tickets.