Ejemplo n.º 1
0
func extractTimestampFromRecord(record string) (utctime.UTCTime, error) {
	timestampStr := record[:len(utctime.Default)]
	return utctime.ParseLocaltime(utctime.Default, timestampStr)
}
Ejemplo n.º 2
0
func extractTimestampFromJoblog(joblog string) (utctime.UTCTime, error) {
	parts := strings.Split(joblog, ".")
	timestampStr := strings.Join(parts[len(parts)-3:len(parts)-1], ".")
	return utctime.ParseLocaltime(utctime.NoDelimiter, timestampStr)
}