gocardless / theatre

GoCardless' collection of Kubernetes extensions
MIT License
23 stars 17 forks source link

Console Event IDs: Use UTC timestamps #265

Closed benwh closed 2 years ago

benwh commented 2 years ago

The NewConsoleEventID function is supposed to return a deterministic string in relation to a given console.

The time.Time object contains data about the local timezone, and time.Format() uses this, therefore stamping out a timestamp string which matches local time.

We never want to do this; the string returned from this function should be the same across all environments, regardless of what the local timezone is set to, therefore we need to convert to UTC before formatting.