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

cloud auto discovery in CHINA region #8073

Closed
fwrq41251 opened this issue May 3, 2016 · 7 comments

Comments

Projects
None yet
4 participants
@fwrq41251
Copy link

commented May 3, 2016

<aws enabled=”true”>
<access-key>my-access-key</access-key>
<secret-key>my-secret-key</secret-key>
<region>us-east-1</region>
<host-header>ec2.amazonaws.com</host-header>
<security-group-name>sg-hazelcast</security-group-name>
<tag-key>type</tag-key>
<tag-value>hz-nodes</tag-value>
</aws>

when the region is set to "cn-north-1",
server raise a exception:
java.net.UnknownHostException: ec2.cn-north-1.amazonaws.com
and the host should be ec2.cn-north-1.amazonaws.com.cn.
and when host-header is set to "ec2.cn-north-1.amazonaws.com.cn",
the config does not work.
does hazelcast now version support china region or not ?

@fwrq41251

This comment has been minimized.

Copy link
Author

commented May 3, 2016

ps:i am using hazelcast version:3.2.6

@noctarius

This comment has been minimized.

Copy link
Contributor

commented May 3, 2016

Did you try to configure host-header for China?

<host-header>ec2.amazonaws.com.cn</host-header>

PS: You're using a pretty old version of Hazelcast which might not work anymore when old datacenters deactivate old signature algorithm for signing REST API requests.

@fwrq41251

This comment has been minimized.

Copy link
Author

commented May 3, 2016

@noctarius
i have tried this.
so the newest version support china region? and how should the config be like?

@mesutcelik

This comment has been minimized.

Copy link
Contributor

commented May 3, 2016

here is the latest doc. I don't see any config change.
http://docs.hazelcast.org/docs/latest/manual/html-single/index.html#discovering-members-within-ec2-cloud

Can you please try with the latest stable version that is hazelcast 3.6.2

@bilalyasar

This comment has been minimized.

Copy link
Collaborator

commented May 3, 2016

This issue is very similar to #5653 and it was already solved with 3.5.2

@fwrq41251

This comment has been minimized.

Copy link
Author

commented May 4, 2016

i have taken a look at code in hazelcast 3.6.2.

endpoint = awsConfig.getHostHeader();
if (awsConfig.getRegion() != null && awsConfig.getRegion().length() > 0) {
    setEndpoint("ec2." + awsConfig.getRegion() + ".amazonaws.com");
}

since the region in awsconfig cannot be set to empty(the set method has an empty check),the host-header config will never work?

@mesutcelik mesutcelik added this to the 3.6.3 milestone May 4, 2016

mesutcelik added a commit that referenced this issue May 11, 2016

@mesutcelik

This comment has been minimized.

Copy link
Contributor

commented May 11, 2016

fixed by #8102

@mesutcelik mesutcelik closed this May 11, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.