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.
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, andtime.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.