I have a tab-delimited logs with such messages:
2014-06-01 00:00:56 192.168.1.1 968 http://yandex.ru
I can extract date and time with regexp (\d{4}-\d{2}-\d{2}\s*\d{2}:\d{2}:\d{2})
but when I try to convert it to timestamp with pattern yyyy-MM-dd hh:mm:ss
it fails with error:
MapperParsingException[failed to parse [timestamp]]; nested: MapperParsingException[failed to parse date field [2014-06-01 00:00:56], tried both date format [yyyy-MM-dd HH:mm:ss.SSS], and timestamp number with locale []]; nested: IllegalArgumentException[Invalid format: "2014-06-01 00:00:56" is malformed at " 00:00:56"];
I suggest it happens because I have a space in the pattern between date and time parts instead a tab between them in the message. But I don't know, how to fix it.