Skip to content

HBASE-25292 Improve InetSocketAddress usage discipline - #2669

Merged
Apache9 merged 4 commits into
apache:masterfrom
apurtell:HBASE-25292
Nov 28, 2020
Merged

HBASE-25292 Improve InetSocketAddress usage discipline#2669
Apache9 merged 4 commits into
apache:masterfrom
apurtell:HBASE-25292

Conversation

@apurtell

@apurtellapurtell commented Nov 17, 2020

Copy link
Copy Markdown
Contributor

We sometimes cache InetSocketAddress in data structures in an attempt to optimize away potential nameservice (DNS) lookups. This is, in general, an anti-pattern, because once an InetSocketAddress is resolved, resolution is never attempted again. The ideal pattern for connect() is ISA instantiation just before the connect() call, with no reuse of the ISA instance. For bind() we presume the local identity won't change while the process is live so usage and caching can be relaxed in that case.

Network identities should be bound late. This means addresses should be resolved at the last possible moment. Also, network identity mappings can change, so our code should not inappropriately cache them; otherwise we might miss a change and fail to operate normally. This is especially important in public cloud and Kubernetes settings, where network identities will change as VM or container instances are replaced.

I have reviewed the code for InetSocketAddress usage and in my opinion sometimes we are caching ISA acceptably, and in other cases we are not.

Correct cases:

  • We cache ISA for RPC connections, so we don't potentially do a lookup for every Call. However, we resolve the address earlier than we need to. The code can be improved by moving resolution to just before where we connect().
  • Use of ISA with bind. Typical uses like bindAddress, listenerAddress, initialIsa, or localAddress.
    • (There is no harm to keep direct use of ISA for bind() but these could all be replaced with Address and on-demand create of ISA just before bind().
  • ClusterStatusPublisher in master.
  • Netty integration. Netty accepts and supplies ISA, no choice there, but we want to resolve at channel create time and cache for lifetime of the channel anyway. If a remote host goes away and is replaced with a new identity, a new channel/connection will be created with a new resolution just before connect() via higher layer error handling.

Incorrect cases that can be fixed:

  • RPC stubs. Remote clients may be recycled and replaced with new instances where the network identities (DNS name to IP address mapping) have changed--. HBASE-14544 attempts to work around DNS instability in data centers of years past in a way that, in my opinion, is the wrong thing to do in the modern era. In modern datacenters, in public cloud, and especially in kubernetes environments, DNS mappings are dynamic and subject to frequent change. It is just never the right thing to do to cache them. I intend to propose a revert of HBASE-14544. Reverting this simplifies some code a bit. That is the only reason: this is in my opinion some legacy that can be dropped, one fewer configuration variable (yay!), but if this part of the proposal is controversial it can be skipped.
  • RPC stubs again. When looking up the IP address of the remote host when creating a stub key we also make a key even if the resolution fails. This is the wrong thing to do. If we can't resolve the remote address, we can't contact the server. Making a stub that can't communicate is pointless. Throw an exception instead.
  • Favored nodes. Although the HDFS API requires InetSocketAddress, we don't have to make up a list right away and cache them forever. We can use Address to record the list of favored nodes and convert from Address to InetSocketAddress on demand (when we go to create the HFile). This will allow us to resolve datanode hostnames just before they are needed. In public cloud, kubernetes, and or some private datacenter service deployment options, datanode servers may have their network identities (DNS name -> IP address mapping) changed over time. We can and should avoid inappropriate caching that may cause us to indefinitely use an incorrect address when contacting a favored node.
  • Sometimes we use ISA when Address is just as good. For example, the dead servers list. If we are going to pay some attention to ISA usage discipline, let's remove the cases where we use ISA as a host and port pair but do not need to do so. Address works just as well and doesn't present an opportunity for misuse. I only make this change where we use ISA as a map key. We should be explicit about whether or not we key by hostname plus port and/or by resolved address.
    • We could do a lot more substitutions than what is proposed. All of the ISA uses with bind() are okay as is but could also be updated.

Incorrect cases that cannot be fixed:

  • hbase-external-blockcache: We have to resolve all of the memcached locations up front because the memcached client constructor requires ISA instances. So we have to hope that the network identities (DNS name -> IP address mapping) does not change for any in the list. This is beyond our control.

While in this area it is trivial to add new client connect metrics for number of potential nameservice lookups (whenever we instantiate an ISA) and number of failed nameservice lookups (if the instantiated ISA is unresolved).

While in this area I also noticed we often directly access a field in ConnectionId where there is also a getter, so good practice is to use the getter instead.

this.socket.bind(this.rpcClient.localAddr);
}
NetUtils.connect(this.socket, remoteId.getAddress(), this.rpcClient.connectTO);
if (this.rpcClient.metrics != null) {

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

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

This change is a forward port of the branch-1 change here: https://github.com/apache/hbase/pull/2671/files#diff-1a7ec27a8107293b6c87132823c262fc250570687a40f45646c43ae46dc6b04eR255

This change fixes a bug we encountered in production while running in Amazon's Elastic Kubernetes Service.

assert eventLoop.inEventLoop();
LOG.trace("Connecting to {}", remoteId.address);

LOG.trace("Connecting to {}", remoteId.getAddress());

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

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

@Apache-HBase

Copy link
Copy Markdown

🎊 +1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec0m 28sDocker mode activated.
_ Prechecks _
+1 💚dupname0m 0sNo case conflicting files found.
+1 💚hbaseanti0m 0sPatch does not have any anti-patterns.
+1 💚@author0m 0sThe patch does not contain any @author tags.
_ master Compile Tests _
+0 🆗mvndep0m 23sMaven dependency ordering for branch
+1 💚mvninstall3m 43smaster passed
+1 💚checkstyle2m 19smaster passed
+1 💚spotbugs4m 35smaster passed
_ Patch Compile Tests _
+0 🆗mvndep0m 13sMaven dependency ordering for patch
+1 💚mvninstall3m 27sthe patch passed
-0 ⚠️checkstyle0m 27shbase-client: The patch generated 3 new + 8 unchanged - 1 fixed = 11 total (was 9)
-0 ⚠️checkstyle1m 7shbase-server: The patch generated 1 new + 46 unchanged - 0 fixed = 47 total (was 46)
+1 💚whitespace0m 0sThe patch has no whitespace issues.
+1 💚hadoopcheck17m 8sPatch does not cause any errors with Hadoop 3.1.2 3.2.1 3.3.0.
+1 💚spotbugs5m 25sthe patch passed
_ Other Tests _
+1 💚asflicense1m 4sThe patch does not generate ASF License warnings.
49m 41s
SubsystemReport/Notes
DockerClientAPI=1.40 ServerAPI=1.40 base: https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/1/artifact/yetus-general-check/output/Dockerfile
GITHUB PR#2669
Optional Testsdupname asflicense spotbugs hadoopcheck hbaseanti checkstyle
unameLinux 53cd53ce86e2 4.15.0-112-generic #113-Ubuntu SMP Thu Jul 9 23:41:39 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionmaster / ca129e9
checkstylehttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/1/artifact/yetus-general-check/output/diff-checkstyle-hbase-client.txt
checkstylehttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/1/artifact/yetus-general-check/output/diff-checkstyle-hbase-server.txt
Max. process+thread count94 (vs. ulimit of 30000)
modulesC: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console outputhttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/1/console
versionsgit=2.17.1 maven=3.6.3 spotbugs=3.1.12
Powered byApache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase

Copy link
Copy Markdown

🎊 +1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec0m 28sDocker mode activated.
-0 ⚠️yetus0m 3sUnprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗mvndep0m 22sMaven dependency ordering for branch
+1 💚mvninstall4m 14smaster passed
+1 💚compile2m 38smaster passed
+1 💚shadedjars6m 40sbranch has no errors when building our shaded downstream artifacts.
+1 💚javadoc2m 9smaster passed
_ Patch Compile Tests _
+0 🆗mvndep0m 16sMaven dependency ordering for patch
+1 💚mvninstall4m 9sthe patch passed
+1 💚compile2m 39sthe patch passed
+1 💚javac2m 40sthe patch passed
+1 💚shadedjars6m 43spatch has no errors when building our shaded downstream artifacts.
+1 💚javadoc2m 6sthe patch passed
_ Other Tests _
+1 💚unit1m 31shbase-common in the patch passed.
+1 💚unit1m 10shbase-client in the patch passed.
+1 💚unit0m 44shbase-zookeeper in the patch passed.
+1 💚unit132m 11shbase-server in the patch passed.
+1 💚unit0m 48shbase-external-blockcache in the patch passed.
172m 0s
SubsystemReport/Notes
DockerClientAPI=1.40 ServerAPI=1.40 base: https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/1/artifact/yetus-jdk11-hadoop3-check/output/Dockerfile
GITHUB PR#2669
Optional Testsjavac javadoc unit shadedjars compile
unameLinux 2bdf9876b141 4.15.0-60-generic #67-Ubuntu SMP Thu Aug 22 16:55:30 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionmaster / ca129e9
Default JavaAdoptOpenJDK-11.0.6+10
Test Resultshttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/1/testReport/
Max. process+thread count3978 (vs. ulimit of 30000)
modulesC: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console outputhttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/1/console
versionsgit=2.17.1 maven=3.6.3
Powered byApache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase

Copy link
Copy Markdown

🎊 +1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec1m 4sDocker mode activated.
-0 ⚠️yetus0m 3sUnprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗mvndep0m 22sMaven dependency ordering for branch
+1 💚mvninstall3m 43smaster passed
+1 💚compile2m 24smaster passed
+1 💚shadedjars6m 35sbranch has no errors when building our shaded downstream artifacts.
+1 💚javadoc1m 51smaster passed
_ Patch Compile Tests _
+0 🆗mvndep0m 16sMaven dependency ordering for patch
+1 💚mvninstall3m 27sthe patch passed
+1 💚compile2m 23sthe patch passed
+1 💚javac2m 23sthe patch passed
+1 💚shadedjars6m 29spatch has no errors when building our shaded downstream artifacts.
+1 💚javadoc1m 54sthe patch passed
_ Other Tests _
+1 💚unit1m 24shbase-common in the patch passed.
+1 💚unit0m 59shbase-client in the patch passed.
+1 💚unit0m 43shbase-zookeeper in the patch passed.
+1 💚unit147m 7shbase-server in the patch passed.
+1 💚unit0m 43shbase-external-blockcache in the patch passed.
184m 30s
SubsystemReport/Notes
DockerClientAPI=1.40 ServerAPI=1.40 base: https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/1/artifact/yetus-jdk8-hadoop3-check/output/Dockerfile
GITHUB PR#2669
Optional Testsjavac javadoc unit shadedjars compile
unameLinux 5f37c7312dc8 4.15.0-112-generic #113-Ubuntu SMP Thu Jul 9 23:41:39 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionmaster / ca129e9
Default JavaAdoptOpenJDK-1.8.0_232-b09
Test Resultshttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/1/testReport/
Max. process+thread count4294 (vs. ulimit of 30000)
modulesC: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console outputhttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/1/console
versionsgit=2.17.1 maven=3.6.3
Powered byApache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache9Apache9 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

The patch is big and I do not have enough time to fully review it. Will go out for a business trip until Friday so I think I need to deal with HBASE-18070 first.

In general I'm a big +1 on the approach here. Let's use our Addresss as much as possible in our code.

The creation of InetSocketAddress will introduce a dns lookup which could be very slow, and once it is created it will never resolve again, and if you use InetSocketAddress.createUnresolved, you will get trouble if you forget to resolve it when passing to connection related methods. Glad to see that we plan to improve it.

Thanks.

// DNS name is different but IP address remains the same.
String hostname = serverName.getHostname();
int port = serverName.getPort();
// We used to ignore when the address was unresolvable but that makes no sense. It

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I do not think the old behavior is to ignore the unresolveable address? It just wants to make the stub key shorter and do not need to actual do a DNS lookup if we can make sure that the hostname will not change. And this is important for an async implementation, as we do not expect this method to be blocked but a DNS lookup could take several seconds if the the hostname can not be resolved.

And in general, I never understand why here we need to add the ip address in the stub key... We have timestamp in server name so we could know whether it is the same region server, and for the rpc framework, there is no problem that they have the same stub key? We just use a string here and once we want to connect, we will resolve it and it will point to the correct ip address. We could point the hostname of a regionserver to another regionserver while both the regionservers are alive and can accept requests? This is not a good practice and can cause big troubles... I guess once we have done this, the old regionserver need to reconnect to master to again to tell master that its hostname has been changed?

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

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

So we should use the ServerName here directly to make the key instead?

I can do that. Let me make the change.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I'm not sure whether we really need to identify different region servers here. What is the problem if we just use host and port as the stub key here? It will not be a problem if we will resolve it when we actually connecting the remote side? Thoughts?

private int maxConcurrentCallsPerServer;

private static final LoadingCache<InetSocketAddress, AtomicInteger> concurrentCounterCache =
private static final LoadingCache<Address, AtomicInteger> concurrentCounterCache =

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Good. When implementing an in-house rpc framework in the past, I used to use InetSocketAddress.createUnresolved. But it has a problem that usually a network framework will not accept a unresolved InetSocketAddress so if you forget to recreate a resolved one you will get exception. Since here we have a special structure, I think it is good to make use it to explicitly say that, here we do not want a resolve yet.

final Message param, Message returnType, final User ticket, final InetSocketAddress addr,
final RpcCallback<Message> callback) {
final Message param, Message returnType, final User ticket,
final InetSocketAddress inetAddr, final RpcCallback<Message> callback) {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Could we change this to use Address directly? And we could also remove the UnknownHostException from the createAddr method then which could makes the createRpcChannel and createBlockingRpcChannel not throw IOException, which will be very good.

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

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

Let me check.

What we want to avoid is making an ISA for every Call.

Will try this and get back to you.

@apurtellapurtellNov 18, 2020

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

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

I can't do this or else there will be a new InetSocketAddress() for every callMethod(), which may cause a DNS lookup per call.

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

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

Ok, done. Lookup done upon first call and then cached there; or else an exception or failure indication is returned at that time.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Can not view the code now but IIRC, on this execution path, we will use a ConnectionId to get a RpcConnection and then use it to send the rpc call? Then I think we could put the actual resolving in the connect method? Before connecting we could always use the Address class to represent the remote address.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Checked the code, I think we could avoid creating an InetSocketAddress everytime here, we just need to change more classes to make use of Address instead of InetSocketAddress, such as ConnetionId, FailedServers, as well as the RpcClient interface. And the resolving of the actual address could be delayed to NettyRpcConnection.connect and BlockingRpcConnection.setupConnection, where we really want to connect to the remote side. And once the connection has been established, and it has not been closed because of error or idle for too long, we do not need to involve InetSocketAddress again. I think it is OK?

final User ticket;
final String serviceName;
final InetSocketAddress address;
final Address address;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Good.

@apurtell

Copy link
Copy Markdown
ContributorAuthor

In the description I said this:

Use of ISA with bind. Typical uses like bindAddress, listenerAddress, initialIsa, or localAddress.
(There is no harm to keep direct use of ISA for bind() but these could all be replaced with Address and on-demand create of ISA just before bind().

Based on positive feedback from @Apache9 on the overall approach I will be more aggressive in replacing ISA with Address, for bind() cases too. It will be a separate commit on the PR branch so can be undone if there is a later concern.

@apurtell
apurtellforce-pushed the HBASE-25292 branch 3 times, most recently from 09b6eeb to eaece7eCompareNovember 18, 2020 22:26
@Apache-HBase

Copy link
Copy Markdown

🎊 +1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec0m 37sDocker mode activated.
_ Prechecks _
+1 💚dupname0m 0sNo case conflicting files found.
+1 💚hbaseanti0m 0sPatch does not have any anti-patterns.
+1 💚@author0m 0sThe patch does not contain any @author tags.
_ master Compile Tests _
+0 🆗mvndep0m 22sMaven dependency ordering for branch
+1 💚mvninstall3m 46smaster passed
+1 💚checkstyle2m 23smaster passed
+1 💚spotbugs4m 37smaster passed
_ Patch Compile Tests _
+0 🆗mvndep0m 13sMaven dependency ordering for patch
+1 💚mvninstall3m 28sthe patch passed
-0 ⚠️checkstyle0m 27shbase-client: The patch generated 5 new + 8 unchanged - 1 fixed = 13 total (was 9)
-0 ⚠️checkstyle1m 5shbase-server: The patch generated 1 new + 46 unchanged - 0 fixed = 47 total (was 46)
+1 💚whitespace0m 0sThe patch has no whitespace issues.
+1 💚hadoopcheck17m 50sPatch does not cause any errors with Hadoop 3.1.2 3.2.1 3.3.0.
+1 💚spotbugs6m 57sthe patch passed
_ Other Tests _
+1 💚asflicense0m 59sThe patch does not generate ASF License warnings.
53m 3s
SubsystemReport/Notes
DockerClientAPI=1.40 ServerAPI=1.40 base: https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/2/artifact/yetus-general-check/output/Dockerfile
GITHUB PR#2669
Optional Testsdupname asflicense spotbugs hadoopcheck hbaseanti checkstyle
unameLinux a0f1f9c0b723 4.15.0-58-generic #64-Ubuntu SMP Tue Aug 6 11:12:41 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionmaster / 9419c78
checkstylehttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/2/artifact/yetus-general-check/output/diff-checkstyle-hbase-client.txt
checkstylehttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/2/artifact/yetus-general-check/output/diff-checkstyle-hbase-server.txt
Max. process+thread count94 (vs. ulimit of 30000)
modulesC: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console outputhttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/2/console
versionsgit=2.17.1 maven=3.6.3 spotbugs=3.1.12
Powered byApache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase

Copy link
Copy Markdown

💔 -1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec0m 29sDocker mode activated.
-0 ⚠️yetus0m 3sUnprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗mvndep0m 22sMaven dependency ordering for branch
+1 💚mvninstall4m 12smaster passed
+1 💚compile2m 38smaster passed
+1 💚shadedjars6m 34sbranch has no errors when building our shaded downstream artifacts.
+1 💚javadoc2m 8smaster passed
_ Patch Compile Tests _
+0 🆗mvndep0m 15sMaven dependency ordering for patch
+1 💚mvninstall4m 3sthe patch passed
+1 💚compile2m 43sthe patch passed
+1 💚javac2m 43sthe patch passed
+1 💚shadedjars6m 39spatch has no errors when building our shaded downstream artifacts.
+1 💚javadoc2m 7sthe patch passed
_ Other Tests _
+1 💚unit1m 32shbase-common in the patch passed.
+1 💚unit1m 10shbase-client in the patch passed.
+1 💚unit0m 45shbase-zookeeper in the patch passed.
-1 ❌unit133m 18shbase-server in the patch failed.
+1 💚unit0m 45shbase-external-blockcache in the patch passed.
172m 40s
SubsystemReport/Notes
DockerClientAPI=1.40 ServerAPI=1.40 base: https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/2/artifact/yetus-jdk11-hadoop3-check/output/Dockerfile
GITHUB PR#2669
Optional Testsjavac javadoc unit shadedjars compile
unameLinux f68abb17a8a5 4.15.0-60-generic #67-Ubuntu SMP Thu Aug 22 16:55:30 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionmaster / 9419c78
Default JavaAdoptOpenJDK-11.0.6+10
unithttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/2/artifact/yetus-jdk11-hadoop3-check/output/patch-unit-hbase-server.txt
Test Resultshttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/2/testReport/
Max. process+thread count4012 (vs. ulimit of 30000)
modulesC: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console outputhttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/2/console
versionsgit=2.17.1 maven=3.6.3
Powered byApache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase

Copy link
Copy Markdown

🎊 +1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec1m 10sDocker mode activated.
-0 ⚠️yetus0m 3sUnprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗mvndep0m 20sMaven dependency ordering for branch
+1 💚mvninstall4m 5smaster passed
+1 💚compile2m 22smaster passed
+1 💚shadedjars7m 11sbranch has no errors when building our shaded downstream artifacts.
+1 💚javadoc1m 48smaster passed
_ Patch Compile Tests _
+0 🆗mvndep0m 14sMaven dependency ordering for patch
+1 💚mvninstall3m 54sthe patch passed
+1 💚compile2m 24sthe patch passed
+1 💚javac2m 24sthe patch passed
+1 💚shadedjars7m 7spatch has no errors when building our shaded downstream artifacts.
+1 💚javadoc1m 47sthe patch passed
_ Other Tests _
+1 💚unit1m 33shbase-common in the patch passed.
+1 💚unit1m 12shbase-client in the patch passed.
+1 💚unit0m 44shbase-zookeeper in the patch passed.
+1 💚unit207m 4shbase-server in the patch passed.
+1 💚unit0m 37shbase-external-blockcache in the patch passed.
245m 54s
SubsystemReport/Notes
DockerClientAPI=1.40 ServerAPI=1.40 base: https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/2/artifact/yetus-jdk8-hadoop3-check/output/Dockerfile
GITHUB PR#2669
Optional Testsjavac javadoc unit shadedjars compile
unameLinux 01e3d4b8208f 4.15.0-112-generic #113-Ubuntu SMP Thu Jul 9 23:41:39 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionmaster / 9419c78
Default JavaAdoptOpenJDK-1.8.0_232-b09
Test Resultshttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/2/testReport/
Max. process+thread count3733 (vs. ulimit of 30000)
modulesC: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console outputhttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/2/console
versionsgit=2.17.1 maven=3.6.3
Powered byApache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase

Copy link
Copy Markdown

🎊 +1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec0m 28sDocker mode activated.
_ Prechecks _
+1 💚dupname0m 1sNo case conflicting files found.
+1 💚hbaseanti0m 0sPatch does not have any anti-patterns.
+1 💚@author0m 0sThe patch does not contain any @author tags.
_ master Compile Tests _
+0 🆗mvndep0m 25sMaven dependency ordering for branch
+1 💚mvninstall3m 38smaster passed
+1 💚checkstyle2m 19smaster passed
+1 💚spotbugs4m 41smaster passed
_ Patch Compile Tests _
+0 🆗mvndep0m 14sMaven dependency ordering for patch
+1 💚mvninstall3m 34sthe patch passed
-0 ⚠️checkstyle0m 29shbase-client: The patch generated 5 new + 8 unchanged - 1 fixed = 13 total (was 9)
-0 ⚠️checkstyle1m 22shbase-server: The patch generated 1 new + 46 unchanged - 0 fixed = 47 total (was 46)
+1 💚whitespace0m 0sThe patch has no whitespace issues.
+1 💚hadoopcheck22m 5sPatch does not cause any errors with Hadoop 3.1.2 3.2.1 3.3.0.
+1 💚spotbugs6m 40sthe patch passed
_ Other Tests _
+1 💚asflicense1m 4sThe patch does not generate ASF License warnings.
58m 6s
SubsystemReport/Notes
DockerClientAPI=1.40 ServerAPI=1.40 base: https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/3/artifact/yetus-general-check/output/Dockerfile
GITHUB PR#2669
Optional Testsdupname asflicense spotbugs hadoopcheck hbaseanti checkstyle
unameLinux 856972f282a9 4.15.0-58-generic #64-Ubuntu SMP Tue Aug 6 11:12:41 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionmaster / 8c1e476
checkstylehttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/3/artifact/yetus-general-check/output/diff-checkstyle-hbase-client.txt
checkstylehttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/3/artifact/yetus-general-check/output/diff-checkstyle-hbase-server.txt
Max. process+thread count94 (vs. ulimit of 30000)
modulesC: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console outputhttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/3/console
versionsgit=2.17.1 maven=3.6.3 spotbugs=3.1.12
Powered byApache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase

Copy link
Copy Markdown

💔 -1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec0m 28sDocker mode activated.
-0 ⚠️yetus0m 3sUnprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗mvndep0m 26sMaven dependency ordering for branch
+1 💚mvninstall4m 0smaster passed
+1 💚compile2m 39smaster passed
+1 💚shadedjars6m 43sbranch has no errors when building our shaded downstream artifacts.
+1 💚javadoc2m 4smaster passed
_ Patch Compile Tests _
+0 🆗mvndep0m 15sMaven dependency ordering for patch
+1 💚mvninstall4m 6sthe patch passed
+1 💚compile2m 39sthe patch passed
+1 💚javac2m 39sthe patch passed
+1 💚shadedjars6m 34spatch has no errors when building our shaded downstream artifacts.
+1 💚javadoc2m 6sthe patch passed
_ Other Tests _
+1 💚unit1m 30shbase-common in the patch passed.
+1 💚unit1m 10shbase-client in the patch passed.
+1 💚unit0m 44shbase-zookeeper in the patch passed.
-1 ❌unit133m 10shbase-server in the patch failed.
+1 💚unit0m 36shbase-external-blockcache in the patch passed.
172m 22s
SubsystemReport/Notes
DockerClientAPI=1.40 ServerAPI=1.40 base: https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/3/artifact/yetus-jdk11-hadoop3-check/output/Dockerfile
GITHUB PR#2669
Optional Testsjavac javadoc unit shadedjars compile
unameLinux 49f72050374a 4.15.0-60-generic #67-Ubuntu SMP Thu Aug 22 16:55:30 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionmaster / 8c1e476
Default JavaAdoptOpenJDK-11.0.6+10
unithttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/3/artifact/yetus-jdk11-hadoop3-check/output/patch-unit-hbase-server.txt
Test Resultshttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/3/testReport/
Max. process+thread count3966 (vs. ulimit of 30000)
modulesC: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console outputhttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/3/console
versionsgit=2.17.1 maven=3.6.3
Powered byApache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase

Copy link
Copy Markdown

💔 -1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec1m 3sDocker mode activated.
-0 ⚠️yetus0m 4sUnprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗mvndep0m 22sMaven dependency ordering for branch
+1 💚mvninstall3m 46smaster passed
+1 💚compile2m 24smaster passed
+1 💚shadedjars6m 34sbranch has no errors when building our shaded downstream artifacts.
+1 💚javadoc1m 51smaster passed
_ Patch Compile Tests _
+0 🆗mvndep0m 16sMaven dependency ordering for patch
+1 💚mvninstall3m 30sthe patch passed
+1 💚compile2m 22sthe patch passed
+1 💚javac2m 22sthe patch passed
+1 💚shadedjars6m 34spatch has no errors when building our shaded downstream artifacts.
+1 💚javadoc1m 52sthe patch passed
_ Other Tests _
+1 💚unit1m 23shbase-common in the patch passed.
+1 💚unit1m 1shbase-client in the patch passed.
+1 💚unit0m 44shbase-zookeeper in the patch passed.
-1 ❌unit147m 52shbase-server in the patch failed.
+1 💚unit0m 37shbase-external-blockcache in the patch passed.
185m 17s
SubsystemReport/Notes
DockerClientAPI=1.40 ServerAPI=1.40 base: https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/3/artifact/yetus-jdk8-hadoop3-check/output/Dockerfile
GITHUB PR#2669
Optional Testsjavac javadoc unit shadedjars compile
unameLinux e8bad9c59944 4.15.0-112-generic #113-Ubuntu SMP Thu Jul 9 23:41:39 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionmaster / 8c1e476
Default JavaAdoptOpenJDK-1.8.0_232-b09
unithttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/3/artifact/yetus-jdk8-hadoop3-check/output/patch-unit-hbase-server.txt
Test Resultshttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/3/testReport/
Max. process+thread count4507 (vs. ulimit of 30000)
modulesC: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console outputhttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/3/console
versionsgit=2.17.1 maven=3.6.3
Powered byApache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@virajjasani

Copy link
Copy Markdown
Contributor

testGetAdminBadHostname() failure seems relevant?

@virajjasanivirajjasani left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Overall looks positive, using Address seems quite better choice than caching InetSocketAddress. I am still trying to understand some code paths (specifically the ones related to RpcConnection) better.

Comment on lines 27 to +28
import java.net.InetAddress;
import java.net.InetSocketAddress;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

nit: both InetAddress and InetSocketAddress are no longer in use, imports can be removed.

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

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

Ok. There are going to be other checkstyle nits too, will look at the report and fix them all.

Comment on lines +31 to +32
import java.net.InetAddress;
import java.net.InetSocketAddress;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

nit: same here, no longer in use.

@Override
public InetSocketAddress[] getFavoredNodesForRegion(String encodedRegionName) {
return regionFavoredNodesMap.get(encodedRegionName);
return Address.toSocketAddress(regionFavoredNodesMap.get(encodedRegionName));

@virajjasanivirajjasaniNov 19, 2020

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

This conversion to InetSocketAddress[] takes place for each new StoreFileWriter creation right? Is there any other usecase that I am missing here?

@virajjasanivirajjasaniNov 19, 2020

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Where do we check if these addresses are resolved? Or we don't need to for this specific use-case?

@apurtellapurtellNov 19, 2020

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

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

This will happen whenever the regionserver needs to build a list of ISA of datanodes for handing to FileSystem#create, but only if Favored Nodes is enabled. (As far as I know, nobody actually uses favored nodes, well, perhaps Francis and ex-Yahoo team.) So yeah, just before store file creation time. We can hand the ISA directly to HDFS without checking ISA#isUnresolved because should an ISA be unresolved when HDFS tries to use it the Java network API will throw an exception, which will propagate up to us. However if you would prefer to check the resolution status of the ISAs and explicitly throw our own exception, the place to do this would be FSUtils.java where the call to FileSystem#create including ISA parameters is performed via reflection.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

the place to do this would be FSUtils.java where the call to FileSystem#create including ISA parameters is performed via reflection.

Oh, what a giant reflection happening here :)

 return (FSDataOutputStream) (DistributedFileSystem.class
.getDeclaredMethod("create", Path.class, FsPermission.class, boolean.class, int.class,
short.class, long.class, Progressable.class, InetSocketAddress[].class)
.invoke(backingFs, path, perm, true, CommonFSUtils.getDefaultBufferSize(backingFs),
replication > 0 ? replication : CommonFSUtils.getDefaultReplication(backingFs, path),
CommonFSUtils.getDefaultBlockSize(backingFs, path), null, favoredNodes));

We can hand the ISA directly to HDFS without checking ISA#isUnresolved because should an ISA be unresolved when HDFS tries to use it the Java network API will throw an exception, which will propagate up to us.

Makes sense, I think we should be good with this as is, rather than performing resolution checks at both layers.

@apurtell

Copy link
Copy Markdown
ContributorAuthor

testGetAdminBadHostname() is relevant

Yeah, this test is going to have to change or maybe go away. I will look at it.

@apurtell

apurtell commented Nov 19, 2020

Copy link
Copy Markdown
ContributorAuthor

I decided not to try replacing ISA with Address for bind() use cases. The problem there is it leads to a lot of conversions between Address and ISA, back and forth. Frameworks like Java networking and Netty have methods that receive and return ISA. Whenever we call them, we have to make a conversion.

An ISA created to represent a local identity for bind() does not have the same issues with caching that an ISA created to represent a remote identity for connect(). The local network identity is not expected to change over the lifetime of the process. If the container, VM, or server instance is replaced with a new instance with a new network identity, all currently running processes can be expected to be terminated as part of that action.

I am not contemplating further changes on this PR beyond fixes needed for checkstyle, findbugs, or unit test findings.

That said, if there is strong opinion that we should continue the replacement of ISA with Address for the bind() code paths, I will certainly do that for you. Be advised there will be a lot of conversions back and forth (akin to the many conversions between byte[] and String that bedevil us sometimes).

@Apache-HBase

Copy link
Copy Markdown

🎊 +1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec0m 28sDocker mode activated.
_ Prechecks _
+1 💚dupname0m 0sNo case conflicting files found.
+1 💚hbaseanti0m 0sPatch does not have any anti-patterns.
+1 💚@author0m 0sThe patch does not contain any @author tags.
_ master Compile Tests _
+0 🆗mvndep0m 26sMaven dependency ordering for branch
+1 💚mvninstall3m 43smaster passed
+1 💚checkstyle2m 20smaster passed
+1 💚spotbugs4m 36smaster passed
_ Patch Compile Tests _
+0 🆗mvndep0m 13sMaven dependency ordering for patch
+1 💚mvninstall3m 25sthe patch passed
-0 ⚠️checkstyle0m 27shbase-client: The patch generated 5 new + 8 unchanged - 1 fixed = 13 total (was 9)
-0 ⚠️checkstyle1m 6shbase-server: The patch generated 1 new + 46 unchanged - 0 fixed = 47 total (was 46)
+1 💚whitespace0m 0sThe patch has no whitespace issues.
+1 💚hadoopcheck17m 2sPatch does not cause any errors with Hadoop 3.1.2 3.2.1 3.3.0.
+1 💚spotbugs5m 22sthe patch passed
_ Other Tests _
+1 💚asflicense1m 2sThe patch does not generate ASF License warnings.
49m 33s
SubsystemReport/Notes
DockerClientAPI=1.40 ServerAPI=1.40 base: https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/4/artifact/yetus-general-check/output/Dockerfile
GITHUB PR#2669
Optional Testsdupname asflicense spotbugs hadoopcheck hbaseanti checkstyle
unameLinux 355e2ad70ca5 4.15.0-58-generic #64-Ubuntu SMP Tue Aug 6 11:12:41 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionmaster / 30ef3aa
checkstylehttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/4/artifact/yetus-general-check/output/diff-checkstyle-hbase-client.txt
checkstylehttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/4/artifact/yetus-general-check/output/diff-checkstyle-hbase-server.txt
Max. process+thread count94 (vs. ulimit of 30000)
modulesC: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console outputhttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/4/console
versionsgit=2.17.1 maven=3.6.3 spotbugs=3.1.12
Powered byApache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase

Copy link
Copy Markdown

💔 -1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec0m 48sDocker mode activated.
-0 ⚠️yetus0m 3sUnprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗mvndep0m 32sMaven dependency ordering for branch
+1 💚mvninstall4m 39smaster passed
+1 💚compile2m 49smaster passed
+1 💚shadedjars8m 16sbranch has no errors when building our shaded downstream artifacts.
+1 💚javadoc2m 31smaster passed
_ Patch Compile Tests _
+0 🆗mvndep0m 18sMaven dependency ordering for patch
+1 💚mvninstall5m 19sthe patch passed
+1 💚compile3m 12sthe patch passed
+1 💚javac3m 12sthe patch passed
+1 💚shadedjars8m 51spatch has no errors when building our shaded downstream artifacts.
+1 💚javadoc2m 25sthe patch passed
_ Other Tests _
+1 💚unit1m 45shbase-common in the patch passed.
+1 💚unit1m 19shbase-client in the patch passed.
+1 💚unit0m 51shbase-zookeeper in the patch passed.
-1 ❌unit138m 26shbase-server in the patch failed.
+1 💚unit0m 36shbase-external-blockcache in the patch passed.
185m 55s
SubsystemReport/Notes
DockerClientAPI=1.40 ServerAPI=1.40 base: https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/4/artifact/yetus-jdk11-hadoop3-check/output/Dockerfile
GITHUB PR#2669
Optional Testsjavac javadoc unit shadedjars compile
unameLinux 21db47025ecc 4.15.0-60-generic #67-Ubuntu SMP Thu Aug 22 16:55:30 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionmaster / 30ef3aa
Default JavaAdoptOpenJDK-11.0.6+10
unithttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/4/artifact/yetus-jdk11-hadoop3-check/output/patch-unit-hbase-server.txt
Test Resultshttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/4/testReport/
Max. process+thread count4051 (vs. ulimit of 30000)
modulesC: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console outputhttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/4/console
versionsgit=2.17.1 maven=3.6.3
Powered byApache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase

Copy link
Copy Markdown

💔 -1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec0m 40sDocker mode activated.
-0 ⚠️yetus0m 5sUnprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗mvndep0m 23sMaven dependency ordering for branch
+1 💚mvninstall4m 19smaster passed
+1 💚compile2m 39smaster passed
+1 💚shadedjars7m 57sbranch has no errors when building our shaded downstream artifacts.
+1 💚javadoc2m 1smaster passed
_ Patch Compile Tests _
+0 🆗mvndep0m 18sMaven dependency ordering for patch
+1 💚mvninstall4m 8sthe patch passed
+1 💚compile2m 40sthe patch passed
+1 💚javac2m 40sthe patch passed
+1 💚shadedjars7m 48spatch has no errors when building our shaded downstream artifacts.
+1 💚javadoc1m 58sthe patch passed
_ Other Tests _
+1 💚unit1m 38shbase-common in the patch passed.
+1 💚unit1m 7shbase-client in the patch passed.
+1 💚unit0m 44shbase-zookeeper in the patch passed.
-1 ❌unit147m 6shbase-server in the patch failed.
+1 💚unit0m 38shbase-external-blockcache in the patch passed.
189m 23s
SubsystemReport/Notes
DockerClientAPI=1.40 ServerAPI=1.40 base: https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/4/artifact/yetus-jdk8-hadoop3-check/output/Dockerfile
GITHUB PR#2669
Optional Testsjavac javadoc unit shadedjars compile
unameLinux cbe38acd3957 4.15.0-58-generic #64-Ubuntu SMP Tue Aug 6 11:12:41 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionmaster / 30ef3aa
Default JavaAdoptOpenJDK-1.8.0_232-b09
unithttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/4/artifact/yetus-jdk8-hadoop3-check/output/patch-unit-hbase-server.txt
Test Resultshttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/4/testReport/
Max. process+thread count3768 (vs. ulimit of 30000)
modulesC: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console outputhttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/4/console
versionsgit=2.17.1 maven=3.6.3
Powered byApache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache9

Copy link
Copy Markdown
Contributor

Agree that bind is not important here. One of most the important things we want to fix here is to not cache the resolved address since it could be changed, especially in a container environment. But for bind, usually we will just bind once when starting a service, which means we do not have a chance to resolve it again.

And I'm interest that you have already deployed HBase on K8S environment? Actually I'm running the K8s team at Xiaomi now(the HBase team is running by Guanghao now). If it is OK, would you mind to have an online technical talk with the K8s and HBase team at Xiaomi to talk about your solution?

Thanks.

@apurtell
apurtellforce-pushed the HBASE-25292 branch 2 times, most recently from e33cf77 to 14c3626CompareNovember 20, 2020 22:08

@liuml07liuml07 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I think I reviewed the similar code internally and was +1 on it.

I see some differences here in the patch for master branch, the code still looks good to me.

Thanks.

@liuml07

Copy link
Copy Markdown
Member

I will connect you with the architect at Salesforce leading the HBase on K8S effort (it's not me) and we can maybe the three of us arrange a technical talk. And @liuml07 in our community is on the team and did a lot of the work. If he is willing he could present in Chinese language.

Thanks @apurtell. Our lead in HBase on Kubernetes is @dhirajh He was willing to share our experience in a blog post or talk, and I'm not sure if materials is ready. We can also schedule a meeting sometime after holiday season (early Dec or next year) if mutual interest is there.

@Apache-HBase

Copy link
Copy Markdown

💔 -1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec0m 33sDocker mode activated.
-0 ⚠️yetus0m 3sUnprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗mvndep0m 18sMaven dependency ordering for branch
+1 💚mvninstall4m 9smaster passed
+1 💚compile2m 39smaster passed
+1 💚shadedjars6m 46sbranch has no errors when building our shaded downstream artifacts.
+1 💚javadoc2m 5smaster passed
_ Patch Compile Tests _
+0 🆗mvndep0m 15sMaven dependency ordering for patch
+1 💚mvninstall4m 5sthe patch passed
+1 💚compile2m 42sthe patch passed
+1 💚javac2m 42sthe patch passed
+1 💚shadedjars7m 3spatch has no errors when building our shaded downstream artifacts.
+1 💚javadoc2m 7sthe patch passed
_ Other Tests _
+1 💚unit1m 35shbase-common in the patch passed.
+1 💚unit1m 35shbase-client in the patch passed.
+1 💚unit0m 49shbase-zookeeper in the patch passed.
-1 ❌unit8m 19shbase-server in the patch failed.
+1 💚unit0m 24shbase-external-blockcache in the patch passed.
47m 46s
SubsystemReport/Notes
DockerClientAPI=1.40 ServerAPI=1.40 base: https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/5/artifact/yetus-jdk11-hadoop3-check/output/Dockerfile
GITHUB PR#2669
Optional Testsjavac javadoc unit shadedjars compile
unameLinux c4c2bbde58e5 4.15.0-60-generic #67-Ubuntu SMP Thu Aug 22 16:55:30 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionmaster / eca904e
Default JavaAdoptOpenJDK-11.0.6+10
unithttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/5/artifact/yetus-jdk11-hadoop3-check/output/patch-unit-hbase-server.txt
Test Resultshttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/5/testReport/
Max. process+thread count751 (vs. ulimit of 30000)
modulesC: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console outputhttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/5/console
versionsgit=2.17.1 maven=3.6.3
Powered byApache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase

Copy link
Copy Markdown

🎊 +1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec0m 29sDocker mode activated.
_ Prechecks _
+1 💚dupname0m 0sNo case conflicting files found.
+1 💚hbaseanti0m 0sPatch does not have any anti-patterns.
+1 💚@author0m 0sThe patch does not contain any @author tags.
_ master Compile Tests _
+0 🆗mvndep0m 29sMaven dependency ordering for branch
+1 💚mvninstall3m 25smaster passed
+1 💚checkstyle2m 19smaster passed
+1 💚spotbugs4m 33smaster passed
_ Patch Compile Tests _
+0 🆗mvndep0m 13sMaven dependency ordering for patch
+1 💚mvninstall3m 22sthe patch passed
-0 ⚠️checkstyle0m 26shbase-client: The patch generated 5 new + 8 unchanged - 1 fixed = 13 total (was 9)
-0 ⚠️checkstyle1m 5shbase-server: The patch generated 1 new + 47 unchanged - 0 fixed = 48 total (was 47)
+1 💚whitespace0m 0sThe patch has no whitespace issues.
+1 💚hadoopcheck17m 0sPatch does not cause any errors with Hadoop 3.1.2 3.2.1 3.3.0.
+1 💚spotbugs5m 26sthe patch passed
_ Other Tests _
+1 💚asflicense1m 2sThe patch does not generate ASF License warnings.
48m 57s
SubsystemReport/Notes
DockerClientAPI=1.40 ServerAPI=1.40 base: https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/5/artifact/yetus-general-check/output/Dockerfile
GITHUB PR#2669
Optional Testsdupname asflicense spotbugs hadoopcheck hbaseanti checkstyle
unameLinux 31104e09993c 4.15.0-58-generic #64-Ubuntu SMP Tue Aug 6 11:12:41 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionmaster / eca904e
checkstylehttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/5/artifact/yetus-general-check/output/diff-checkstyle-hbase-client.txt
checkstylehttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/5/artifact/yetus-general-check/output/diff-checkstyle-hbase-server.txt
Max. process+thread count94 (vs. ulimit of 30000)
modulesC: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console outputhttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/5/console
versionsgit=2.17.1 maven=3.6.3 spotbugs=3.1.12
Powered byApache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@apurtell

Copy link
Copy Markdown
ContributorAuthor

Great, let's set up an online get-together if all are agreeable @dhirajh@liuml07@Apache9

@Apache-HBase

Copy link
Copy Markdown

🎊 +1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec1m 9sDocker mode activated.
-0 ⚠️yetus0m 3sUnprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗mvndep0m 30sMaven dependency ordering for branch
+1 💚mvninstall3m 29smaster passed
+1 💚compile2m 22smaster passed
+1 💚shadedjars6m 37sbranch has no errors when building our shaded downstream artifacts.
+1 💚javadoc1m 53smaster passed
_ Patch Compile Tests _
+0 🆗mvndep0m 16sMaven dependency ordering for patch
+1 💚mvninstall3m 33sthe patch passed
+1 💚compile2m 22sthe patch passed
+1 💚javac2m 22sthe patch passed
+1 💚shadedjars6m 31spatch has no errors when building our shaded downstream artifacts.
+1 💚javadoc1m 53sthe patch passed
_ Other Tests _
+1 💚unit1m 23shbase-common in the patch passed.
+1 💚unit1m 1shbase-client in the patch passed.
+1 💚unit0m 42shbase-zookeeper in the patch passed.
+1 💚unit148m 15shbase-server in the patch passed.
+1 💚unit0m 43shbase-external-blockcache in the patch passed.
185m 46s
SubsystemReport/Notes
DockerClientAPI=1.40 ServerAPI=1.40 base: https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/5/artifact/yetus-jdk8-hadoop3-check/output/Dockerfile
GITHUB PR#2669
Optional Testsjavac javadoc unit shadedjars compile
unameLinux cf32e92b8137 4.15.0-112-generic #113-Ubuntu SMP Thu Jul 9 23:41:39 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionmaster / eca904e
Default JavaAdoptOpenJDK-1.8.0_232-b09
Test Resultshttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/5/testReport/
Max. process+thread count4120 (vs. ulimit of 30000)
modulesC: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console outputhttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/5/console
versionsgit=2.17.1 maven=3.6.3
Powered byApache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache9

Copy link
Copy Markdown
Contributor

I will connect you with the architect at Salesforce leading the HBase on K8S effort (it's not me) and we can maybe the three of us arrange a technical talk. And @liuml07 in our community is on the team and did a lot of the work. If he is willing he could present in Chinese language.

Thanks @apurtell. Our lead in HBase on Kubernetes is @dhirajh He was willing to share our experience in a blog post or talk, and I'm not sure if materials is ready. We can also schedule a meeting sometime after holiday season (early Dec or next year) if mutual interest is there.

A blog post first will be good. We could read the blog post first to find out the things we have interest and want to know more details, then we could set up the topic to discuss in the meeting, which could make the meeting more efficient.

And on the time of the meeting, no hurry. Take your time.

And thanks all for your offers. We could discuss this further with email as this is not related to this PR.

@Apache9

Copy link
Copy Markdown
Contributor

And on the PR, @apurtell please give me sometime to review. I want to take a deep look at the client side code. If you think I'm too late just ping me, and if I still do not have time to finish the review then you are free to merge.

Thanks.

@Apache-HBase

Copy link
Copy Markdown

🎊 +1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec0m 36sDocker mode activated.
_ Prechecks _
+1 💚dupname0m 0sNo case conflicting files found.
+1 💚hbaseanti0m 0sPatch does not have any anti-patterns.
+1 💚@author0m 0sThe patch does not contain any @author tags.
_ master Compile Tests _
+0 🆗mvndep0m 27sMaven dependency ordering for branch
+1 💚mvninstall3m 41smaster passed
+1 💚checkstyle2m 23smaster passed
+1 💚spotbugs4m 36smaster passed
_ Patch Compile Tests _
+0 🆗mvndep0m 13sMaven dependency ordering for patch
+1 💚mvninstall3m 28sthe patch passed
-0 ⚠️checkstyle0m 27shbase-client: The patch generated 5 new + 8 unchanged - 1 fixed = 13 total (was 9)
-0 ⚠️checkstyle1m 4shbase-server: The patch generated 1 new + 47 unchanged - 0 fixed = 48 total (was 47)
+1 💚whitespace0m 0sThe patch has no whitespace issues.
+1 💚hadoopcheck17m 1sPatch does not cause any errors with Hadoop 3.1.2 3.2.1 3.3.0.
+1 💚spotbugs5m 31sthe patch passed
_ Other Tests _
+1 💚asflicense1m 2sThe patch does not generate ASF License warnings.
49m 44s
SubsystemReport/Notes
DockerClientAPI=1.40 ServerAPI=1.40 base: https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/6/artifact/yetus-general-check/output/Dockerfile
GITHUB PR#2669
Optional Testsdupname asflicense spotbugs hadoopcheck hbaseanti checkstyle
unameLinux 0f776357659c 4.15.0-112-generic #113-Ubuntu SMP Thu Jul 9 23:41:39 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionmaster / eca904e
checkstylehttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/6/artifact/yetus-general-check/output/diff-checkstyle-hbase-client.txt
checkstylehttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/6/artifact/yetus-general-check/output/diff-checkstyle-hbase-server.txt
Max. process+thread count94 (vs. ulimit of 30000)
modulesC: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console outputhttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/6/console
versionsgit=2.17.1 maven=3.6.3 spotbugs=3.1.12
Powered byApache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@apurtell

Copy link
Copy Markdown
ContributorAuthor

There is plenty of time for review, no worries. Will wait.

@dhirajh

Copy link
Copy Markdown

I will connect you with the architect at Salesforce leading the HBase on K8S effort (it's not me) and we can maybe the three of us arrange a technical talk. And @liuml07 in our community is on the team and did a lot of the work. If he is willing he could present in Chinese language.

Thanks @apurtell. Our lead in HBase on Kubernetes is @dhirajh He was willing to share our experience in a blog post or talk, and I'm not sure if materials is ready. We can also schedule a meeting sometime after holiday season (early Dec or next year) if mutual interest is there.

A blog post first will be good. We could read the blog post first to find out the things we have interest and want to know more details, then we could set up the topic to discuss in the meeting, which could make the meeting more efficient.

And on the time of the meeting, no hurry. Take your time.

And thanks all for your offers. We could discuss this further with email as this is not related to this PR.

Thanks for the interest @Apache9 and thanks @apurtell@liuml07 for adding me to the conversation. Sounds good on the plan, the blog post is not yet ready, but will work on getting that out. I am happy to participate in any meetings after that.

@Apache-HBase

Copy link
Copy Markdown

🎊 +1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec0m 34sDocker mode activated.
-0 ⚠️yetus0m 3sUnprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗mvndep0m 33sMaven dependency ordering for branch
+1 💚mvninstall6m 0smaster passed
+1 💚compile2m 52smaster passed
+1 💚shadedjars6m 45sbranch has no errors when building our shaded downstream artifacts.
+1 💚javadoc2m 3smaster passed
_ Patch Compile Tests _
+0 🆗mvndep0m 15sMaven dependency ordering for patch
+1 💚mvninstall4m 3sthe patch passed
+1 💚compile2m 41sthe patch passed
+1 💚javac2m 41sthe patch passed
+1 💚shadedjars6m 41spatch has no errors when building our shaded downstream artifacts.
+1 💚javadoc2m 4sthe patch passed
_ Other Tests _
+1 💚unit1m 29shbase-common in the patch passed.
+1 💚unit1m 9shbase-client in the patch passed.
+1 💚unit0m 44shbase-zookeeper in the patch passed.
+1 💚unit134m 9shbase-server in the patch passed.
+1 💚unit0m 36shbase-external-blockcache in the patch passed.
175m 54s
SubsystemReport/Notes
DockerClientAPI=1.40 ServerAPI=1.40 base: https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/6/artifact/yetus-jdk11-hadoop3-check/output/Dockerfile
GITHUB PR#2669
Optional Testsjavac javadoc unit shadedjars compile
unameLinux 3c1431062f29 4.15.0-60-generic #67-Ubuntu SMP Thu Aug 22 16:55:30 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionmaster / eca904e
Default JavaAdoptOpenJDK-11.0.6+10
Test Resultshttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/6/testReport/
Max. process+thread count4120 (vs. ulimit of 30000)
modulesC: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console outputhttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/6/console
versionsgit=2.17.1 maven=3.6.3
Powered byApache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase

Copy link
Copy Markdown

🎊 +1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec1m 13sDocker mode activated.
-0 ⚠️yetus0m 3sUnprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗mvndep0m 23sMaven dependency ordering for branch
+1 💚mvninstall3m 25smaster passed
+1 💚compile2m 24smaster passed
+1 💚shadedjars6m 37sbranch has no errors when building our shaded downstream artifacts.
+1 💚javadoc1m 52smaster passed
_ Patch Compile Tests _
+0 🆗mvndep0m 15sMaven dependency ordering for patch
+1 💚mvninstall3m 29sthe patch passed
+1 💚compile2m 21sthe patch passed
+1 💚javac2m 21sthe patch passed
+1 💚shadedjars6m 33spatch has no errors when building our shaded downstream artifacts.
+1 💚javadoc1m 51sthe patch passed
_ Other Tests _
+1 💚unit1m 24shbase-common in the patch passed.
+1 💚unit1m 2shbase-client in the patch passed.
+1 💚unit0m 43shbase-zookeeper in the patch passed.
+1 💚unit148m 14shbase-server in the patch passed.
+1 💚unit0m 35shbase-external-blockcache in the patch passed.
185m 28s
SubsystemReport/Notes
DockerClientAPI=1.40 ServerAPI=1.40 base: https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/6/artifact/yetus-jdk8-hadoop3-check/output/Dockerfile
GITHUB PR#2669
Optional Testsjavac javadoc unit shadedjars compile
unameLinux c042212bd015 4.15.0-112-generic #113-Ubuntu SMP Thu Jul 9 23:41:39 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionmaster / eca904e
Default JavaAdoptOpenJDK-1.8.0_232-b09
Test Resultshttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/6/testReport/
Max. process+thread count4030 (vs. ulimit of 30000)
modulesC: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console outputhttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/6/console
versionsgit=2.17.1 maven=3.6.3
Powered byApache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

apurtelland others added 4 commits November 25, 2020 14:36
Network identities should be bound late. Remote addresses should be
resolved at the last possible moment, just before connect(). Network
identity mappings can change, so our code should not inappropriately
cache them. Otherwise we might miss a change and fail to operate normally.
Revert "HBASE-14544 Allow HConnectionImpl to not refresh the dns on errors"
Removes hbase.resolve.hostnames.on.failure and related code. We always
resolve hostnames, as late as possible.
Preserve InetSocketAddress caching per RPC connection. Avoids potential
lookups per Call.
Replace InetSocketAddress with Address where used as a map key. If we want
to key by hostname and/or resolved address we should be explicit about it.
Using Address chooses mapping by hostname and port only.
Add metrics for potential nameservice resolution attempts, whenever an
InetSocketAddress is instantiated for connect; and metrics for failed
resolution, whenever InetSocketAddress#isUnresolved on the new instance
is true.
We resolve DNS at the latest possible time, at first call, and do not
resolve hostnames for creating stubs at all, so this unit test cannot
work now.
@Apache-HBase

Copy link
Copy Markdown

🎊 +1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec0m 28sDocker mode activated.
_ Prechecks _
+1 💚dupname0m 0sNo case conflicting files found.
+1 💚hbaseanti0m 0sPatch does not have any anti-patterns.
+1 💚@author0m 0sThe patch does not contain any @author tags.
_ master Compile Tests _
+0 🆗mvndep0m 22sMaven dependency ordering for branch
+1 💚mvninstall3m 42smaster passed
+1 💚checkstyle2m 18smaster passed
+1 💚spotbugs4m 54smaster passed
_ Patch Compile Tests _
+0 🆗mvndep0m 14sMaven dependency ordering for patch
+1 💚mvninstall3m 29sthe patch passed
-0 ⚠️checkstyle0m 26shbase-client: The patch generated 5 new + 7 unchanged - 1 fixed = 12 total (was 8)
-0 ⚠️checkstyle1m 3shbase-server: The patch generated 1 new + 46 unchanged - 0 fixed = 47 total (was 46)
+1 💚whitespace0m 0sThe patch has no whitespace issues.
+1 💚hadoopcheck17m 26sPatch does not cause any errors with Hadoop 3.1.2 3.2.1 3.3.0.
+1 💚spotbugs5m 53sthe patch passed
_ Other Tests _
+1 💚asflicense1m 0sThe patch does not generate ASF License warnings.
50m 25s
SubsystemReport/Notes
DockerClientAPI=1.40 ServerAPI=1.40 base: https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/7/artifact/yetus-general-check/output/Dockerfile
GITHUB PR#2669
Optional Testsdupname asflicense spotbugs hadoopcheck hbaseanti checkstyle
unameLinux d3a5598a79d7 4.15.0-58-generic #64-Ubuntu SMP Tue Aug 6 11:12:41 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionmaster / 1726160
checkstylehttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/7/artifact/yetus-general-check/output/diff-checkstyle-hbase-client.txt
checkstylehttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/7/artifact/yetus-general-check/output/diff-checkstyle-hbase-server.txt
Max. process+thread count94 (vs. ulimit of 30000)
modulesC: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console outputhttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/7/console
versionsgit=2.17.1 maven=3.6.3 spotbugs=3.1.12
Powered byApache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase

Copy link
Copy Markdown

💔 -1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec0m 29sDocker mode activated.
-0 ⚠️yetus0m 3sUnprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗mvndep0m 33sMaven dependency ordering for branch
+1 💚mvninstall3m 35smaster passed
+1 💚compile2m 23smaster passed
+1 💚shadedjars6m 57sbranch has no errors when building our shaded downstream artifacts.
+1 💚javadoc1m 50smaster passed
_ Patch Compile Tests _
+0 🆗mvndep0m 16sMaven dependency ordering for patch
+1 💚mvninstall3m 31sthe patch passed
+1 💚compile2m 22sthe patch passed
+1 💚javac2m 22sthe patch passed
+1 💚shadedjars6m 50spatch has no errors when building our shaded downstream artifacts.
+1 💚javadoc1m 51sthe patch passed
_ Other Tests _
+1 💚unit1m 37shbase-common in the patch passed.
+1 💚unit1m 6shbase-client in the patch passed.
+1 💚unit0m 42shbase-zookeeper in the patch passed.
-1 ❌unit158m 8shbase-server in the patch failed.
+1 💚unit0m 40shbase-external-blockcache in the patch passed.
195m 36s
SubsystemReport/Notes
DockerClientAPI=1.40 ServerAPI=1.40 base: https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/7/artifact/yetus-jdk8-hadoop3-check/output/Dockerfile
GITHUB PR#2669
Optional Testsjavac javadoc unit shadedjars compile
unameLinux a9988eb0392c 4.15.0-58-generic #64-Ubuntu SMP Tue Aug 6 11:12:41 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionmaster / 1726160
Default JavaAdoptOpenJDK-1.8.0_232-b09
unithttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/7/artifact/yetus-jdk8-hadoop3-check/output/patch-unit-hbase-server.txt
Test Resultshttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/7/testReport/
Max. process+thread count3614 (vs. ulimit of 30000)
modulesC: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console outputhttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/7/console
versionsgit=2.17.1 maven=3.6.3
Powered byApache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase

Copy link
Copy Markdown

💔 -1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec1m 36sDocker mode activated.
-0 ⚠️yetus0m 3sUnprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗mvndep0m 22sMaven dependency ordering for branch
+1 💚mvninstall5m 41smaster passed
+1 💚compile3m 42smaster passed
+1 💚shadedjars8m 15sbranch has no errors when building our shaded downstream artifacts.
+1 💚javadoc2m 19smaster passed
_ Patch Compile Tests _
+0 🆗mvndep0m 17sMaven dependency ordering for patch
+1 💚mvninstall5m 36sthe patch passed
+1 💚compile3m 25sthe patch passed
+1 💚javac3m 25sthe patch passed
+1 💚shadedjars8m 4spatch has no errors when building our shaded downstream artifacts.
+1 💚javadoc2m 25sthe patch passed
_ Other Tests _
+1 💚unit2m 20shbase-common in the patch passed.
+1 💚unit1m 38shbase-client in the patch passed.
+1 💚unit0m 51shbase-zookeeper in the patch passed.
-1 ❌unit215m 36shbase-server in the patch failed.
+1 💚unit0m 36shbase-external-blockcache in the patch passed.
265m 22s
SubsystemReport/Notes
DockerClientAPI=1.40 ServerAPI=1.40 base: https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/7/artifact/yetus-jdk11-hadoop3-check/output/Dockerfile
GITHUB PR#2669
Optional Testsjavac javadoc unit shadedjars compile
unameLinux 6fe84c4c1024 4.15.0-112-generic #113-Ubuntu SMP Thu Jul 9 23:41:39 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personalitydev-support/hbase-personality.sh
git revisionmaster / 1726160
Default JavaAdoptOpenJDK-11.0.6+10
unithttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/7/artifact/yetus-jdk11-hadoop3-check/output/patch-unit-hbase-server.txt
Test Resultshttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/7/testReport/
Max. process+thread count3140 (vs. ulimit of 30000)
modulesC: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console outputhttps://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/7/console
versionsgit=2.17.1 maven=3.6.3
Powered byApache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache9Apache9 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I think what I mentioned about the rpc client related changes could be done as follow ons, so I plan to approve and merge this PR first.
But for the PR for branch-2, I suggest that we merge it after cutting branch-2.4, as without the follow ons I think the improvement is only half done, and it will be a pain to carry a half done improvement through a whole minor release line.

Thanks.

*/
static int retries2Attempts(int retries) {
return Math.max(1, retries == Integer.MAX_VALUE ? Integer.MAX_VALUE : retries + 1);
static String getStubKey(String serviceName, ServerName serverName) {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

As said before, I wonder what is the problem if we just use host:port directly here? In the past I think the problem is that we will not resolve again when connecting, for now, I think the problem has been solved?

final Message param, Message returnType, final User ticket, final InetSocketAddress addr,
final RpcCallback<Message> callback) {
final Message param, Message returnType, final User ticket,
final InetSocketAddress inetAddr, final RpcCallback<Message> callback) {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Checked the code, I think we could avoid creating an InetSocketAddress everytime here, we just need to change more classes to make use of Address instead of InetSocketAddress, such as ConnetionId, FailedServers, as well as the RpcClient interface. And the resolving of the actual address could be delayed to NettyRpcConnection.connect and BlockingRpcConnection.setupConnection, where we really want to connect to the remote side. And once the connection has been established, and it has not been closed because of error or idle for too long, we do not need to involve InetSocketAddress again. I think it is OK?

@Apache9
Apache9 merged commit 679dd7b into apache:masterNov 28, 2020
@apurtell

apurtell commented Dec 4, 2020

Copy link
Copy Markdown
ContributorAuthor

Thank for for the merge @Apache9 . Let me backport to branch-2 and branch-1 now.

@apurtell
apurtell deleted the HBASE-25292 branch December 4, 2020 17:52
asfgit pushed a commit that referenced this pull request Dec 4, 2020
Network identities should be bound late. Remote addresses should be
resolved at the last possible moment, just before connect(). Network
identity mappings can change, so our code should not inappropriately
cache them. Otherwise we might miss a change and fail to operate normally.
Revert "HBASE-14544 Allow HConnectionImpl to not refresh the dns on errors"
Removes hbase.resolve.hostnames.on.failure and related code. We always
resolve hostnames, as late as possible.
Preserve InetSocketAddress caching per RPC connection. Avoids potential
lookups per Call.
Replace InetSocketAddress with Address where used as a map key. If we want
to key by hostname and/or resolved address we should be explicit about it.
Using Address chooses mapping by hostname and port only.
Add metrics for potential nameservice resolution attempts, whenever an
InetSocketAddress is instantiated for connect; and metrics for failed
resolution, whenever InetSocketAddress#isUnresolved on the new instance
is true.
* Use ServerName directly to build a stub key
* Resolve and cache ISA on a RpcChannel as late as possible, at first call
* Remove now invalid unit test TestCIBadHostname
We resolve DNS at the latest possible time, at first call, and do not
resolve hostnames for creating stubs at all, so this unit test cannot
work now.
Reviewed-by: Mingliang Liu <liuml07@apache.org>
Signed-off-by: Duo Zhang <zhangduo@apache.org>
asfgit pushed a commit that referenced this pull request Dec 4, 2020
Network identities should be bound late. Remote addresses should be
resolved at the last possible moment, just before connect(). Network
identity mappings can change, so our code should not inappropriately
cache them. Otherwise we might miss a change and fail to operate normally.
Revert "HBASE-14544 Allow HConnectionImpl to not refresh the dns on errors"
Removes hbase.resolve.hostnames.on.failure and related code. We always
resolve hostnames, as late as possible.
Preserve InetSocketAddress caching per RPC connection. Avoids potential
lookups per Call.
Replace InetSocketAddress with Address where used as a map key. If we want
to key by hostname and/or resolved address we should be explicit about it.
Using Address chooses mapping by hostname and port only.
Add metrics for potential nameservice resolution attempts, whenever an
InetSocketAddress is instantiated for connect; and metrics for failed
resolution, whenever InetSocketAddress#isUnresolved on the new instance
is true.
* Use ServerName directly to build a stub key
* Resolve and cache ISA on a RpcChannel as late as possible, at first call
* Remove now invalid unit test TestCIBadHostname
We resolve DNS at the latest possible time, at first call, and do not
resolve hostnames for creating stubs at all, so this unit test cannot
work now.
Reviewed-by: Mingliang Liu <liuml07@apache.org>
Signed-off-by: Duo Zhang <zhangduo@apache.org>
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants

@apurtell@Apache-HBase@virajjasani@Apache9@liuml07@dhirajh