internetitem / logback-elasticsearch-appender

Logback Elasticsearch Appender
Other
233 stars 137 forks source link

Fix region retrieving in AWSAuthentication #69

Open Shinobi47 opened 4 years ago

Shinobi47 commented 4 years ago

Hello, I was trying to use AWSAuthentication to connect a EC2 instance with Amazon ElasticSearch instance. but I was getting this error while trying to start the app :

com.amazonaws.SdkClientException: Unable to find a region via the region provider chain.

After debugging, the Region was null.

I Fixed the AWSAuthentication in order to get the default region of the server.

I created an Issue too for the matter : https://github.com/internetitem/logback-elasticsearch-appender/issues/70

with this fix, it gets the correct Region.