Logstash constantly losing connection to Elastic

logstash-error

Any ideas? This is happening all the time and is a problem on Logstash (Elastic not showing any errors). My logstash is simply parsing logs on the local machine (Elastic on local machine too) so I have no clue what is wrong.