Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ec2-discovery plugin document is not accurate. #27464

Closed
m15o opened this issue Nov 21, 2017 · 9 comments · Fixed by #30323
Closed

ec2-discovery plugin document is not accurate. #27464

m15o opened this issue Nov 21, 2017 · 9 comments · Fixed by #30323
Assignees
Labels
>bug :Distributed/Discovery-Plugins Anything related to our integration plugins with EC2, GCP and Azure >docs General docs changes good first issue low hanging fruit

Comments

@m15o
Copy link

m15o commented Nov 21, 2017

Elasticsearch version: 6.0.0

Plugins installed: ec2-discovery

Description of the problem including expected versus actual behavior:

ec2 service endpoint to connect to. This will be automatically figured out by the ec2 client based on the instance location, but can be specified explicitly
The document states ec2 service endpoint is automatically figured out by ec2 client, but I need to set the endpoint to make the plugin work.

This document is correct if the plugin uses AmazonEC2ClientBuilder to build AmazonEC2Client instance. But AmazonEC2Client is created directly, so the endpoint is set to default endpoint, "https://ec2.us-east-1.amazonaws.com."

Related #25619

@jpountz
Copy link
Contributor

jpountz commented Nov 21, 2017

cc @dadoonet

@jpountz jpountz added >bug >docs General docs changes labels Nov 21, 2017
@NeckBeardPrince
Copy link

@m15o @dadoonet
Actually it's a bit worse than that.
If you set discovery.ec2.endpoint: us-west-1 it tries to connect to a invalid endpoint.
The default of us-east-1 does not do this.
I had to hard set the endpoint to discovery.ec2.endpoint: ec2.us-west-1.amazonaws.com

Connection request: [route: {s}->https://us-west:443][total kept alive: 0; route allocated: 0 of 50; total allocated: 0 of 50]

@dadoonet
Copy link
Member

dadoonet commented Dec 1, 2017

@NeckBeardPrince this is expected. The doc says that the endpoint should be one of those: http://docs.aws.amazon.com/general/latest/gr/rande.html#ec2_region

dadoonet added a commit to dadoonet/elasticsearch that referenced this issue Dec 20, 2017
Document that we are using by default `ec2.us-east-1.amazonaws.com` as
the EC2 endpoint if not explicitly set.

Also switch to non deprecated method when building the EC2 Client.

Closes elastic#27464.
@sihil
Copy link

sihil commented Jan 8, 2018

Yep, this is a pretty painful experience as it is misleading. Sadly just spent a couple of hours trying to figure out why my eu-west-1 instances were not doing discovery after upgrading and came across this whilst trying to figure out how to specify a region. Definitely keen on #27924 to bring behaviour into line with the documentation.

@debadair debadair added the good first issue low hanging fruit label Mar 28, 2018
@debadair
Copy link
Contributor

Until #27924 happens, let's document that it actually defaults to ec2.us-east-1.amazonaws.com.

@dadoonet
Copy link
Member

@debadair yeah. This is what #27925 actually brings as well.

@dadoonet dadoonet self-assigned this May 2, 2018
dadoonet added a commit to dadoonet/elasticsearch that referenced this issue May 2, 2018
I split elastic#27925 in two parts:

* The documentation fix (this PR)
* The code fix (still in elastic#27925)

Closes elastic#27464.
@colings86 colings86 added the :Distributed/Discovery-Plugins Anything related to our integration plugins with EC2, GCP and Azure label Jun 25, 2018
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-distributed

@bnm22
Copy link

bnm22 commented Sep 26, 2018

+1

@karl-tpio
Copy link

Just wanted to say that i also just got bit by this one.
https://discuss.elastic.co/t/discovery-ec2-plugin-always-tries-to-ping-localhost/160433/4

DaveCTurner pushed a commit that referenced this issue Dec 14, 2018
Today our docs claim that the `discovery-ec2` plugin auto-detects the EC2
endpoint, but this is not the case. This fixes these docs.

Closes #27464.
DaveCTurner pushed a commit that referenced this issue Dec 14, 2018
Today our docs claim that the `discovery-ec2` plugin auto-detects the EC2
endpoint, but this is not the case. This fixes these docs.

Closes #27464.
DaveCTurner pushed a commit that referenced this issue Dec 14, 2018
Today our docs claim that the `discovery-ec2` plugin auto-detects the EC2
endpoint, but this is not the case. This fixes these docs.

Closes #27464.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
>bug :Distributed/Discovery-Plugins Anything related to our integration plugins with EC2, GCP and Azure >docs General docs changes good first issue low hanging fruit
Projects
None yet
10 participants