logstash/logstash — pull request #511 by xiaclo (2013-06-10 04:12:04+00:00)
Title: Update HOSTNAME in grok-patterns

RFC952 states of a hostname: "The last character must not be a minus sign or period."
https://tools.ietf.org/html/rfc952

Some of the limitations in RFC952 were lifted by RFC1123, but not this one.
https://tools.ietf.org/html/rfc1123

The updated regex still allows single character hostnames, but does not allow the final character in any section to be a '-'.