Skip to content

[To rel/0.12] Fix connection refused using session when users forget to set client ip#4566

Merged
OneSizeFitsQuorum merged 2 commits intoapache:rel/0.12from
MrQuansy:client_ip_0.12
Dec 14, 2021
Merged

[To rel/0.12] Fix connection refused using session when users forget to set client ip#4566
OneSizeFitsQuorum merged 2 commits intoapache:rel/0.12from
MrQuansy:client_ip_0.12

Conversation

@MrQuansy
Copy link
Copy Markdown
Contributor

@MrQuansy MrQuansy commented Dec 13, 2021

Users only set internal ip in iotdb-cluster.properties, and they often forget to set the rpc_address (public ip) in iotdb-engine.properties. So the rpc address is the default value(0.0.0.0). Session will cache the 0.0.0.0 endpoint when an insertPlan is redirected.
We want internal ip as private ip and rpc_address as public ip. So if the rpc_address is not set, set it the same with internal ip.

@HTHou HTHou requested a review from qiaojialin December 14, 2021 01:39
Copy link
Copy Markdown
Member

@wangchao316 wangchao316 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hi , I have a little question. why do you alter this?
could you please say reason?

@MrQuansy MrQuansy requested a review from wangchao316 December 14, 2021 03:27
@MrQuansy MrQuansy changed the title [To rel/0.12] fix the client ip bug in cluster [To rel/0.12] Fix connection refused using session when users forget to set client ip Dec 14, 2021
Copy link
Copy Markdown
Contributor

@OneSizeFitsQuorum OneSizeFitsQuorum left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@OneSizeFitsQuorum OneSizeFitsQuorum added Module - Cluster PRs for the cluster module Module - Java Client Native API (Session) labels Dec 14, 2021
@wangchao316
Copy link
Copy Markdown
Member

public ip

For security purposes, we generally do not set public IP addresses. We need to set specific IP addresses and enable the network firewall and filtering.

@OneSizeFitsQuorum
Copy link
Copy Markdown
Contributor

For security purposes, we generally do not set public IP addresses. We need to set specific IP addresses and enable the network firewall and filtering.

We were only concerned about helping users reduce the confusion of writing errors, not security before. Your suggestion is very meaningful. Do you have any suggestions for helping users in this scenario while avoiding security issues?

@wangchao316
Copy link
Copy Markdown
Member

We were only concerned about helping users reduce the confusion of writing errors, not security before. Your suggestion is very meaningful. Do you have any suggestions for helping users in this scenario while avoiding security issues?

this pr could merge, I only suggest that the customer also need to configure the IP address in the production environment.

@OneSizeFitsQuorum
Copy link
Copy Markdown
Contributor

this pr could merge, I only suggest that the customer also need to configure the IP address in the production environment.

Ok, welcome to tell us more about your thoughts on security, so we may need to change our assumptions about public IP.

@OneSizeFitsQuorum OneSizeFitsQuorum merged commit 9b83cae into apache:rel/0.12 Dec 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Module - Cluster PRs for the cluster module Module - Java Client Native API (Session)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants