Metrics: Cache the hostname in class variable Fixes: #7857

Fixes #7858
This commit is contained in:
Jake Landis 2017-07-31 14:17:07 -05:00
parent 5db01eb418
commit eb82bc3893

View file

@ -12,7 +12,7 @@ module LogStash
end
def host
Socket.gethostname
@@host ||= Socket.gethostname
end
def version