Skip to content

Conversation

@apurtell
Copy link
Contributor

@apurtell apurtell commented Nov 17, 2020

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
Contributor Author

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
Contributor Author

Choose a reason for hiding this comment

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

@Apache-HBase
Copy link

🎊 +1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 28s Docker mode activated.
_ Prechecks _
+1 💚 dupname 0m 0s No case conflicting files found.
+1 💚 hbaseanti 0m 0s Patch does not have any anti-patterns.
+1 💚 @author 0m 0s The patch does not contain any @author tags.
_ master Compile Tests _
+0 🆗 mvndep 0m 23s Maven dependency ordering for branch
+1 💚 mvninstall 3m 43s master passed
+1 💚 checkstyle 2m 19s master passed
+1 💚 spotbugs 4m 35s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 13s Maven dependency ordering for patch
+1 💚 mvninstall 3m 27s the patch passed
-0 ⚠️ checkstyle 0m 27s hbase-client: The patch generated 3 new + 8 unchanged - 1 fixed = 11 total (was 9)
-0 ⚠️ checkstyle 1m 7s hbase-server: The patch generated 1 new + 46 unchanged - 0 fixed = 47 total (was 46)
+1 💚 whitespace 0m 0s The patch has no whitespace issues.
+1 💚 hadoopcheck 17m 8s Patch does not cause any errors with Hadoop 3.1.2 3.2.1 3.3.0.
+1 💚 spotbugs 5m 25s the patch passed
_ Other Tests _
+1 💚 asflicense 1m 4s The patch does not generate ASF License warnings.
49m 41s
Subsystem Report/Notes
Docker ClientAPI=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 Tests dupname asflicense spotbugs hadoopcheck hbaseanti checkstyle
uname Linux 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 tool maven
Personality dev-support/hbase-personality.sh
git revision master / ca129e9
checkstyle https://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
checkstyle https://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 count 94 (vs. ulimit of 30000)
modules C: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console output https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/1/console
versions git=2.17.1 maven=3.6.3 spotbugs=3.1.12
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase
Copy link

🎊 +1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 28s Docker mode activated.
-0 ⚠️ yetus 0m 3s Unprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗 mvndep 0m 22s Maven dependency ordering for branch
+1 💚 mvninstall 4m 14s master passed
+1 💚 compile 2m 38s master passed
+1 💚 shadedjars 6m 40s branch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 2m 9s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 16s Maven dependency ordering for patch
+1 💚 mvninstall 4m 9s the patch passed
+1 💚 compile 2m 39s the patch passed
+1 💚 javac 2m 40s the patch passed
+1 💚 shadedjars 6m 43s patch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 2m 6s the patch passed
_ Other Tests _
+1 💚 unit 1m 31s hbase-common in the patch passed.
+1 💚 unit 1m 10s hbase-client in the patch passed.
+1 💚 unit 0m 44s hbase-zookeeper in the patch passed.
+1 💚 unit 132m 11s hbase-server in the patch passed.
+1 💚 unit 0m 48s hbase-external-blockcache in the patch passed.
172m 0s
Subsystem Report/Notes
Docker ClientAPI=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 Tests javac javadoc unit shadedjars compile
uname Linux 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 tool maven
Personality dev-support/hbase-personality.sh
git revision master / ca129e9
Default Java AdoptOpenJDK-11.0.6+10
Test Results https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/1/testReport/
Max. process+thread count 3978 (vs. ulimit of 30000)
modules C: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console output https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/1/console
versions git=2.17.1 maven=3.6.3
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase
Copy link

🎊 +1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 1m 4s Docker mode activated.
-0 ⚠️ yetus 0m 3s Unprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗 mvndep 0m 22s Maven dependency ordering for branch
+1 💚 mvninstall 3m 43s master passed
+1 💚 compile 2m 24s master passed
+1 💚 shadedjars 6m 35s branch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 1m 51s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 16s Maven dependency ordering for patch
+1 💚 mvninstall 3m 27s the patch passed
+1 💚 compile 2m 23s the patch passed
+1 💚 javac 2m 23s the patch passed
+1 💚 shadedjars 6m 29s patch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 1m 54s the patch passed
_ Other Tests _
+1 💚 unit 1m 24s hbase-common in the patch passed.
+1 💚 unit 0m 59s hbase-client in the patch passed.
+1 💚 unit 0m 43s hbase-zookeeper in the patch passed.
+1 💚 unit 147m 7s hbase-server in the patch passed.
+1 💚 unit 0m 43s hbase-external-blockcache in the patch passed.
184m 30s
Subsystem Report/Notes
Docker ClientAPI=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 Tests javac javadoc unit shadedjars compile
uname Linux 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 tool maven
Personality dev-support/hbase-personality.sh
git revision master / ca129e9
Default Java AdoptOpenJDK-1.8.0_232-b09
Test Results https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/1/testReport/
Max. process+thread count 4294 (vs. ulimit of 30000)
modules C: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console output https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/1/console
versions git=2.17.1 maven=3.6.3
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

Copy link
Contributor

@Apache9 Apache9 left a comment

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
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
Contributor Author

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
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
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
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
Contributor Author

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.

Copy link
Contributor Author

@apurtell apurtell Nov 18, 2020

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
Contributor Author

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
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
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
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
Contributor Author

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 apurtell force-pushed the HBASE-25292 branch 3 times, most recently from 09b6eeb to eaece7e Compare November 18, 2020 22:26
@Apache-HBase
Copy link

🎊 +1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 37s Docker mode activated.
_ Prechecks _
+1 💚 dupname 0m 0s No case conflicting files found.
+1 💚 hbaseanti 0m 0s Patch does not have any anti-patterns.
+1 💚 @author 0m 0s The patch does not contain any @author tags.
_ master Compile Tests _
+0 🆗 mvndep 0m 22s Maven dependency ordering for branch
+1 💚 mvninstall 3m 46s master passed
+1 💚 checkstyle 2m 23s master passed
+1 💚 spotbugs 4m 37s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 13s Maven dependency ordering for patch
+1 💚 mvninstall 3m 28s the patch passed
-0 ⚠️ checkstyle 0m 27s hbase-client: The patch generated 5 new + 8 unchanged - 1 fixed = 13 total (was 9)
-0 ⚠️ checkstyle 1m 5s hbase-server: The patch generated 1 new + 46 unchanged - 0 fixed = 47 total (was 46)
+1 💚 whitespace 0m 0s The patch has no whitespace issues.
+1 💚 hadoopcheck 17m 50s Patch does not cause any errors with Hadoop 3.1.2 3.2.1 3.3.0.
+1 💚 spotbugs 6m 57s the patch passed
_ Other Tests _
+1 💚 asflicense 0m 59s The patch does not generate ASF License warnings.
53m 3s
Subsystem Report/Notes
Docker ClientAPI=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 Tests dupname asflicense spotbugs hadoopcheck hbaseanti checkstyle
uname Linux 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 tool maven
Personality dev-support/hbase-personality.sh
git revision master / 9419c78
checkstyle https://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
checkstyle https://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 count 94 (vs. ulimit of 30000)
modules C: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console output https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/2/console
versions git=2.17.1 maven=3.6.3 spotbugs=3.1.12
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 29s Docker mode activated.
-0 ⚠️ yetus 0m 3s Unprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗 mvndep 0m 22s Maven dependency ordering for branch
+1 💚 mvninstall 4m 12s master passed
+1 💚 compile 2m 38s master passed
+1 💚 shadedjars 6m 34s branch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 2m 8s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 15s Maven dependency ordering for patch
+1 💚 mvninstall 4m 3s the patch passed
+1 💚 compile 2m 43s the patch passed
+1 💚 javac 2m 43s the patch passed
+1 💚 shadedjars 6m 39s patch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 2m 7s the patch passed
_ Other Tests _
+1 💚 unit 1m 32s hbase-common in the patch passed.
+1 💚 unit 1m 10s hbase-client in the patch passed.
+1 💚 unit 0m 45s hbase-zookeeper in the patch passed.
-1 ❌ unit 133m 18s hbase-server in the patch failed.
+1 💚 unit 0m 45s hbase-external-blockcache in the patch passed.
172m 40s
Subsystem Report/Notes
Docker ClientAPI=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 Tests javac javadoc unit shadedjars compile
uname Linux 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 tool maven
Personality dev-support/hbase-personality.sh
git revision master / 9419c78
Default Java AdoptOpenJDK-11.0.6+10
unit https://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 Results https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/2/testReport/
Max. process+thread count 4012 (vs. ulimit of 30000)
modules C: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console output https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/2/console
versions git=2.17.1 maven=3.6.3
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase
Copy link

🎊 +1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 1m 10s Docker mode activated.
-0 ⚠️ yetus 0m 3s Unprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗 mvndep 0m 20s Maven dependency ordering for branch
+1 💚 mvninstall 4m 5s master passed
+1 💚 compile 2m 22s master passed
+1 💚 shadedjars 7m 11s branch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 1m 48s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 14s Maven dependency ordering for patch
+1 💚 mvninstall 3m 54s the patch passed
+1 💚 compile 2m 24s the patch passed
+1 💚 javac 2m 24s the patch passed
+1 💚 shadedjars 7m 7s patch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 1m 47s the patch passed
_ Other Tests _
+1 💚 unit 1m 33s hbase-common in the patch passed.
+1 💚 unit 1m 12s hbase-client in the patch passed.
+1 💚 unit 0m 44s hbase-zookeeper in the patch passed.
+1 💚 unit 207m 4s hbase-server in the patch passed.
+1 💚 unit 0m 37s hbase-external-blockcache in the patch passed.
245m 54s
Subsystem Report/Notes
Docker ClientAPI=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 Tests javac javadoc unit shadedjars compile
uname Linux 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 tool maven
Personality dev-support/hbase-personality.sh
git revision master / 9419c78
Default Java AdoptOpenJDK-1.8.0_232-b09
Test Results https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/2/testReport/
Max. process+thread count 3733 (vs. ulimit of 30000)
modules C: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console output https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/2/console
versions git=2.17.1 maven=3.6.3
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase
Copy link

🎊 +1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 28s Docker mode activated.
_ Prechecks _
+1 💚 dupname 0m 1s No case conflicting files found.
+1 💚 hbaseanti 0m 0s Patch does not have any anti-patterns.
+1 💚 @author 0m 0s The patch does not contain any @author tags.
_ master Compile Tests _
+0 🆗 mvndep 0m 25s Maven dependency ordering for branch
+1 💚 mvninstall 3m 38s master passed
+1 💚 checkstyle 2m 19s master passed
+1 💚 spotbugs 4m 41s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 14s Maven dependency ordering for patch
+1 💚 mvninstall 3m 34s the patch passed
-0 ⚠️ checkstyle 0m 29s hbase-client: The patch generated 5 new + 8 unchanged - 1 fixed = 13 total (was 9)
-0 ⚠️ checkstyle 1m 22s hbase-server: The patch generated 1 new + 46 unchanged - 0 fixed = 47 total (was 46)
+1 💚 whitespace 0m 0s The patch has no whitespace issues.
+1 💚 hadoopcheck 22m 5s Patch does not cause any errors with Hadoop 3.1.2 3.2.1 3.3.0.
+1 💚 spotbugs 6m 40s the patch passed
_ Other Tests _
+1 💚 asflicense 1m 4s The patch does not generate ASF License warnings.
58m 6s
Subsystem Report/Notes
Docker ClientAPI=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 Tests dupname asflicense spotbugs hadoopcheck hbaseanti checkstyle
uname Linux 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 tool maven
Personality dev-support/hbase-personality.sh
git revision master / 8c1e476
checkstyle https://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
checkstyle https://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 count 94 (vs. ulimit of 30000)
modules C: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console output https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/3/console
versions git=2.17.1 maven=3.6.3 spotbugs=3.1.12
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 28s Docker mode activated.
-0 ⚠️ yetus 0m 3s Unprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗 mvndep 0m 26s Maven dependency ordering for branch
+1 💚 mvninstall 4m 0s master passed
+1 💚 compile 2m 39s master passed
+1 💚 shadedjars 6m 43s branch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 2m 4s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 15s Maven dependency ordering for patch
+1 💚 mvninstall 4m 6s the patch passed
+1 💚 compile 2m 39s the patch passed
+1 💚 javac 2m 39s the patch passed
+1 💚 shadedjars 6m 34s patch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 2m 6s the patch passed
_ Other Tests _
+1 💚 unit 1m 30s hbase-common in the patch passed.
+1 💚 unit 1m 10s hbase-client in the patch passed.
+1 💚 unit 0m 44s hbase-zookeeper in the patch passed.
-1 ❌ unit 133m 10s hbase-server in the patch failed.
+1 💚 unit 0m 36s hbase-external-blockcache in the patch passed.
172m 22s
Subsystem Report/Notes
Docker ClientAPI=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 Tests javac javadoc unit shadedjars compile
uname Linux 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 tool maven
Personality dev-support/hbase-personality.sh
git revision master / 8c1e476
Default Java AdoptOpenJDK-11.0.6+10
unit https://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 Results https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/3/testReport/
Max. process+thread count 3966 (vs. ulimit of 30000)
modules C: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console output https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/3/console
versions git=2.17.1 maven=3.6.3
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 1m 3s Docker mode activated.
-0 ⚠️ yetus 0m 4s Unprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗 mvndep 0m 22s Maven dependency ordering for branch
+1 💚 mvninstall 3m 46s master passed
+1 💚 compile 2m 24s master passed
+1 💚 shadedjars 6m 34s branch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 1m 51s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 16s Maven dependency ordering for patch
+1 💚 mvninstall 3m 30s the patch passed
+1 💚 compile 2m 22s the patch passed
+1 💚 javac 2m 22s the patch passed
+1 💚 shadedjars 6m 34s patch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 1m 52s the patch passed
_ Other Tests _
+1 💚 unit 1m 23s hbase-common in the patch passed.
+1 💚 unit 1m 1s hbase-client in the patch passed.
+1 💚 unit 0m 44s hbase-zookeeper in the patch passed.
-1 ❌ unit 147m 52s hbase-server in the patch failed.
+1 💚 unit 0m 37s hbase-external-blockcache in the patch passed.
185m 17s
Subsystem Report/Notes
Docker ClientAPI=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 Tests javac javadoc unit shadedjars compile
uname Linux 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 tool maven
Personality dev-support/hbase-personality.sh
git revision master / 8c1e476
Default Java AdoptOpenJDK-1.8.0_232-b09
unit https://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 Results https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/3/testReport/
Max. process+thread count 4507 (vs. ulimit of 30000)
modules C: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console output https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/3/console
versions git=2.17.1 maven=3.6.3
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@virajjasani
Copy link
Contributor

testGetAdminBadHostname() failure seems relevant?

Copy link
Contributor

@virajjasani virajjasani left a comment

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
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
Contributor Author

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
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));
Copy link
Contributor

@virajjasani virajjasani Nov 19, 2020

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?

Copy link
Contributor

@virajjasani virajjasani Nov 19, 2020

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?

Copy link
Contributor Author

@apurtell apurtell Nov 19, 2020

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
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
Contributor Author

testGetAdminBadHostname() is relevant

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

@apurtell
Copy link
Contributor Author

apurtell commented Nov 19, 2020

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

🎊 +1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 28s Docker mode activated.
_ Prechecks _
+1 💚 dupname 0m 0s No case conflicting files found.
+1 💚 hbaseanti 0m 0s Patch does not have any anti-patterns.
+1 💚 @author 0m 0s The patch does not contain any @author tags.
_ master Compile Tests _
+0 🆗 mvndep 0m 26s Maven dependency ordering for branch
+1 💚 mvninstall 3m 43s master passed
+1 💚 checkstyle 2m 20s master passed
+1 💚 spotbugs 4m 36s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 13s Maven dependency ordering for patch
+1 💚 mvninstall 3m 25s the patch passed
-0 ⚠️ checkstyle 0m 27s hbase-client: The patch generated 5 new + 8 unchanged - 1 fixed = 13 total (was 9)
-0 ⚠️ checkstyle 1m 6s hbase-server: The patch generated 1 new + 46 unchanged - 0 fixed = 47 total (was 46)
+1 💚 whitespace 0m 0s The patch has no whitespace issues.
+1 💚 hadoopcheck 17m 2s Patch does not cause any errors with Hadoop 3.1.2 3.2.1 3.3.0.
+1 💚 spotbugs 5m 22s the patch passed
_ Other Tests _
+1 💚 asflicense 1m 2s The patch does not generate ASF License warnings.
49m 33s
Subsystem Report/Notes
Docker ClientAPI=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 Tests dupname asflicense spotbugs hadoopcheck hbaseanti checkstyle
uname Linux 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 tool maven
Personality dev-support/hbase-personality.sh
git revision master / 30ef3aa
checkstyle https://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
checkstyle https://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 count 94 (vs. ulimit of 30000)
modules C: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console output https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/4/console
versions git=2.17.1 maven=3.6.3 spotbugs=3.1.12
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 48s Docker mode activated.
-0 ⚠️ yetus 0m 3s Unprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗 mvndep 0m 32s Maven dependency ordering for branch
+1 💚 mvninstall 4m 39s master passed
+1 💚 compile 2m 49s master passed
+1 💚 shadedjars 8m 16s branch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 2m 31s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 18s Maven dependency ordering for patch
+1 💚 mvninstall 5m 19s the patch passed
+1 💚 compile 3m 12s the patch passed
+1 💚 javac 3m 12s the patch passed
+1 💚 shadedjars 8m 51s patch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 2m 25s the patch passed
_ Other Tests _
+1 💚 unit 1m 45s hbase-common in the patch passed.
+1 💚 unit 1m 19s hbase-client in the patch passed.
+1 💚 unit 0m 51s hbase-zookeeper in the patch passed.
-1 ❌ unit 138m 26s hbase-server in the patch failed.
+1 💚 unit 0m 36s hbase-external-blockcache in the patch passed.
185m 55s
Subsystem Report/Notes
Docker ClientAPI=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 Tests javac javadoc unit shadedjars compile
uname Linux 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 tool maven
Personality dev-support/hbase-personality.sh
git revision master / 30ef3aa
Default Java AdoptOpenJDK-11.0.6+10
unit https://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 Results https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/4/testReport/
Max. process+thread count 4051 (vs. ulimit of 30000)
modules C: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console output https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/4/console
versions git=2.17.1 maven=3.6.3
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 40s Docker mode activated.
-0 ⚠️ yetus 0m 5s Unprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗 mvndep 0m 23s Maven dependency ordering for branch
+1 💚 mvninstall 4m 19s master passed
+1 💚 compile 2m 39s master passed
+1 💚 shadedjars 7m 57s branch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 2m 1s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 18s Maven dependency ordering for patch
+1 💚 mvninstall 4m 8s the patch passed
+1 💚 compile 2m 40s the patch passed
+1 💚 javac 2m 40s the patch passed
+1 💚 shadedjars 7m 48s patch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 1m 58s the patch passed
_ Other Tests _
+1 💚 unit 1m 38s hbase-common in the patch passed.
+1 💚 unit 1m 7s hbase-client in the patch passed.
+1 💚 unit 0m 44s hbase-zookeeper in the patch passed.
-1 ❌ unit 147m 6s hbase-server in the patch failed.
+1 💚 unit 0m 38s hbase-external-blockcache in the patch passed.
189m 23s
Subsystem Report/Notes
Docker ClientAPI=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 Tests javac javadoc unit shadedjars compile
uname Linux 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 tool maven
Personality dev-support/hbase-personality.sh
git revision master / 30ef3aa
Default Java AdoptOpenJDK-1.8.0_232-b09
unit https://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 Results https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/4/testReport/
Max. process+thread count 3768 (vs. ulimit of 30000)
modules C: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console output https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/4/console
versions git=2.17.1 maven=3.6.3
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache9
Copy link
Contributor

Apache9 commented Nov 20, 2020

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 apurtell force-pushed the HBASE-25292 branch 2 times, most recently from e33cf77 to 14c3626 Compare November 20, 2020 22:08
Copy link
Member

@liuml07 liuml07 left a comment

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
Member

liuml07 commented Nov 20, 2020

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

💔 -1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 33s Docker mode activated.
-0 ⚠️ yetus 0m 3s Unprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗 mvndep 0m 18s Maven dependency ordering for branch
+1 💚 mvninstall 4m 9s master passed
+1 💚 compile 2m 39s master passed
+1 💚 shadedjars 6m 46s branch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 2m 5s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 15s Maven dependency ordering for patch
+1 💚 mvninstall 4m 5s the patch passed
+1 💚 compile 2m 42s the patch passed
+1 💚 javac 2m 42s the patch passed
+1 💚 shadedjars 7m 3s patch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 2m 7s the patch passed
_ Other Tests _
+1 💚 unit 1m 35s hbase-common in the patch passed.
+1 💚 unit 1m 35s hbase-client in the patch passed.
+1 💚 unit 0m 49s hbase-zookeeper in the patch passed.
-1 ❌ unit 8m 19s hbase-server in the patch failed.
+1 💚 unit 0m 24s hbase-external-blockcache in the patch passed.
47m 46s
Subsystem Report/Notes
Docker ClientAPI=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 Tests javac javadoc unit shadedjars compile
uname Linux 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 tool maven
Personality dev-support/hbase-personality.sh
git revision master / eca904e
Default Java AdoptOpenJDK-11.0.6+10
unit https://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 Results https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/5/testReport/
Max. process+thread count 751 (vs. ulimit of 30000)
modules C: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console output https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/5/console
versions git=2.17.1 maven=3.6.3
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase
Copy link

🎊 +1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 29s Docker mode activated.
_ Prechecks _
+1 💚 dupname 0m 0s No case conflicting files found.
+1 💚 hbaseanti 0m 0s Patch does not have any anti-patterns.
+1 💚 @author 0m 0s The patch does not contain any @author tags.
_ master Compile Tests _
+0 🆗 mvndep 0m 29s Maven dependency ordering for branch
+1 💚 mvninstall 3m 25s master passed
+1 💚 checkstyle 2m 19s master passed
+1 💚 spotbugs 4m 33s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 13s Maven dependency ordering for patch
+1 💚 mvninstall 3m 22s the patch passed
-0 ⚠️ checkstyle 0m 26s hbase-client: The patch generated 5 new + 8 unchanged - 1 fixed = 13 total (was 9)
-0 ⚠️ checkstyle 1m 5s hbase-server: The patch generated 1 new + 47 unchanged - 0 fixed = 48 total (was 47)
+1 💚 whitespace 0m 0s The patch has no whitespace issues.
+1 💚 hadoopcheck 17m 0s Patch does not cause any errors with Hadoop 3.1.2 3.2.1 3.3.0.
+1 💚 spotbugs 5m 26s the patch passed
_ Other Tests _
+1 💚 asflicense 1m 2s The patch does not generate ASF License warnings.
48m 57s
Subsystem Report/Notes
Docker ClientAPI=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 Tests dupname asflicense spotbugs hadoopcheck hbaseanti checkstyle
uname Linux 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 tool maven
Personality dev-support/hbase-personality.sh
git revision master / eca904e
checkstyle https://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
checkstyle https://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 count 94 (vs. ulimit of 30000)
modules C: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console output https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/5/console
versions git=2.17.1 maven=3.6.3 spotbugs=3.1.12
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@apurtell
Copy link
Contributor Author

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

@Apache-HBase
Copy link

🎊 +1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 1m 9s Docker mode activated.
-0 ⚠️ yetus 0m 3s Unprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗 mvndep 0m 30s Maven dependency ordering for branch
+1 💚 mvninstall 3m 29s master passed
+1 💚 compile 2m 22s master passed
+1 💚 shadedjars 6m 37s branch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 1m 53s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 16s Maven dependency ordering for patch
+1 💚 mvninstall 3m 33s the patch passed
+1 💚 compile 2m 22s the patch passed
+1 💚 javac 2m 22s the patch passed
+1 💚 shadedjars 6m 31s patch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 1m 53s the patch passed
_ Other Tests _
+1 💚 unit 1m 23s hbase-common in the patch passed.
+1 💚 unit 1m 1s hbase-client in the patch passed.
+1 💚 unit 0m 42s hbase-zookeeper in the patch passed.
+1 💚 unit 148m 15s hbase-server in the patch passed.
+1 💚 unit 0m 43s hbase-external-blockcache in the patch passed.
185m 46s
Subsystem Report/Notes
Docker ClientAPI=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 Tests javac javadoc unit shadedjars compile
uname Linux 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 tool maven
Personality dev-support/hbase-personality.sh
git revision master / eca904e
Default Java AdoptOpenJDK-1.8.0_232-b09
Test Results https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/5/testReport/
Max. process+thread count 4120 (vs. ulimit of 30000)
modules C: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console output https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/5/console
versions git=2.17.1 maven=3.6.3
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache9
Copy link
Contributor

Apache9 commented Nov 21, 2020

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
Contributor

Apache9 commented Nov 21, 2020

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

🎊 +1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 36s Docker mode activated.
_ Prechecks _
+1 💚 dupname 0m 0s No case conflicting files found.
+1 💚 hbaseanti 0m 0s Patch does not have any anti-patterns.
+1 💚 @author 0m 0s The patch does not contain any @author tags.
_ master Compile Tests _
+0 🆗 mvndep 0m 27s Maven dependency ordering for branch
+1 💚 mvninstall 3m 41s master passed
+1 💚 checkstyle 2m 23s master passed
+1 💚 spotbugs 4m 36s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 13s Maven dependency ordering for patch
+1 💚 mvninstall 3m 28s the patch passed
-0 ⚠️ checkstyle 0m 27s hbase-client: The patch generated 5 new + 8 unchanged - 1 fixed = 13 total (was 9)
-0 ⚠️ checkstyle 1m 4s hbase-server: The patch generated 1 new + 47 unchanged - 0 fixed = 48 total (was 47)
+1 💚 whitespace 0m 0s The patch has no whitespace issues.
+1 💚 hadoopcheck 17m 1s Patch does not cause any errors with Hadoop 3.1.2 3.2.1 3.3.0.
+1 💚 spotbugs 5m 31s the patch passed
_ Other Tests _
+1 💚 asflicense 1m 2s The patch does not generate ASF License warnings.
49m 44s
Subsystem Report/Notes
Docker ClientAPI=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 Tests dupname asflicense spotbugs hadoopcheck hbaseanti checkstyle
uname Linux 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 tool maven
Personality dev-support/hbase-personality.sh
git revision master / eca904e
checkstyle https://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
checkstyle https://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 count 94 (vs. ulimit of 30000)
modules C: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console output https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/6/console
versions git=2.17.1 maven=3.6.3 spotbugs=3.1.12
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@apurtell
Copy link
Contributor Author

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

@dhirajh
Copy link

dhirajh commented Nov 21, 2020

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

🎊 +1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 34s Docker mode activated.
-0 ⚠️ yetus 0m 3s Unprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗 mvndep 0m 33s Maven dependency ordering for branch
+1 💚 mvninstall 6m 0s master passed
+1 💚 compile 2m 52s master passed
+1 💚 shadedjars 6m 45s branch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 2m 3s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 15s Maven dependency ordering for patch
+1 💚 mvninstall 4m 3s the patch passed
+1 💚 compile 2m 41s the patch passed
+1 💚 javac 2m 41s the patch passed
+1 💚 shadedjars 6m 41s patch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 2m 4s the patch passed
_ Other Tests _
+1 💚 unit 1m 29s hbase-common in the patch passed.
+1 💚 unit 1m 9s hbase-client in the patch passed.
+1 💚 unit 0m 44s hbase-zookeeper in the patch passed.
+1 💚 unit 134m 9s hbase-server in the patch passed.
+1 💚 unit 0m 36s hbase-external-blockcache in the patch passed.
175m 54s
Subsystem Report/Notes
Docker ClientAPI=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 Tests javac javadoc unit shadedjars compile
uname Linux 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 tool maven
Personality dev-support/hbase-personality.sh
git revision master / eca904e
Default Java AdoptOpenJDK-11.0.6+10
Test Results https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/6/testReport/
Max. process+thread count 4120 (vs. ulimit of 30000)
modules C: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console output https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/6/console
versions git=2.17.1 maven=3.6.3
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase
Copy link

🎊 +1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 1m 13s Docker mode activated.
-0 ⚠️ yetus 0m 3s Unprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗 mvndep 0m 23s Maven dependency ordering for branch
+1 💚 mvninstall 3m 25s master passed
+1 💚 compile 2m 24s master passed
+1 💚 shadedjars 6m 37s branch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 1m 52s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 15s Maven dependency ordering for patch
+1 💚 mvninstall 3m 29s the patch passed
+1 💚 compile 2m 21s the patch passed
+1 💚 javac 2m 21s the patch passed
+1 💚 shadedjars 6m 33s patch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 1m 51s the patch passed
_ Other Tests _
+1 💚 unit 1m 24s hbase-common in the patch passed.
+1 💚 unit 1m 2s hbase-client in the patch passed.
+1 💚 unit 0m 43s hbase-zookeeper in the patch passed.
+1 💚 unit 148m 14s hbase-server in the patch passed.
+1 💚 unit 0m 35s hbase-external-blockcache in the patch passed.
185m 28s
Subsystem Report/Notes
Docker ClientAPI=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 Tests javac javadoc unit shadedjars compile
uname Linux 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 tool maven
Personality dev-support/hbase-personality.sh
git revision master / eca904e
Default Java AdoptOpenJDK-1.8.0_232-b09
Test Results https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/6/testReport/
Max. process+thread count 4030 (vs. ulimit of 30000)
modules C: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console output https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/6/console
versions git=2.17.1 maven=3.6.3
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

apurtell and 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

🎊 +1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 28s Docker mode activated.
_ Prechecks _
+1 💚 dupname 0m 0s No case conflicting files found.
+1 💚 hbaseanti 0m 0s Patch does not have any anti-patterns.
+1 💚 @author 0m 0s The patch does not contain any @author tags.
_ master Compile Tests _
+0 🆗 mvndep 0m 22s Maven dependency ordering for branch
+1 💚 mvninstall 3m 42s master passed
+1 💚 checkstyle 2m 18s master passed
+1 💚 spotbugs 4m 54s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 14s Maven dependency ordering for patch
+1 💚 mvninstall 3m 29s the patch passed
-0 ⚠️ checkstyle 0m 26s hbase-client: The patch generated 5 new + 7 unchanged - 1 fixed = 12 total (was 8)
-0 ⚠️ checkstyle 1m 3s hbase-server: The patch generated 1 new + 46 unchanged - 0 fixed = 47 total (was 46)
+1 💚 whitespace 0m 0s The patch has no whitespace issues.
+1 💚 hadoopcheck 17m 26s Patch does not cause any errors with Hadoop 3.1.2 3.2.1 3.3.0.
+1 💚 spotbugs 5m 53s the patch passed
_ Other Tests _
+1 💚 asflicense 1m 0s The patch does not generate ASF License warnings.
50m 25s
Subsystem Report/Notes
Docker ClientAPI=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 Tests dupname asflicense spotbugs hadoopcheck hbaseanti checkstyle
uname Linux 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 tool maven
Personality dev-support/hbase-personality.sh
git revision master / 1726160
checkstyle https://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
checkstyle https://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 count 94 (vs. ulimit of 30000)
modules C: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console output https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/7/console
versions git=2.17.1 maven=3.6.3 spotbugs=3.1.12
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 0m 29s Docker mode activated.
-0 ⚠️ yetus 0m 3s Unprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗 mvndep 0m 33s Maven dependency ordering for branch
+1 💚 mvninstall 3m 35s master passed
+1 💚 compile 2m 23s master passed
+1 💚 shadedjars 6m 57s branch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 1m 50s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 16s Maven dependency ordering for patch
+1 💚 mvninstall 3m 31s the patch passed
+1 💚 compile 2m 22s the patch passed
+1 💚 javac 2m 22s the patch passed
+1 💚 shadedjars 6m 50s patch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 1m 51s the patch passed
_ Other Tests _
+1 💚 unit 1m 37s hbase-common in the patch passed.
+1 💚 unit 1m 6s hbase-client in the patch passed.
+1 💚 unit 0m 42s hbase-zookeeper in the patch passed.
-1 ❌ unit 158m 8s hbase-server in the patch failed.
+1 💚 unit 0m 40s hbase-external-blockcache in the patch passed.
195m 36s
Subsystem Report/Notes
Docker ClientAPI=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 Tests javac javadoc unit shadedjars compile
uname Linux 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 tool maven
Personality dev-support/hbase-personality.sh
git revision master / 1726160
Default Java AdoptOpenJDK-1.8.0_232-b09
unit https://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 Results https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/7/testReport/
Max. process+thread count 3614 (vs. ulimit of 30000)
modules C: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console output https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/7/console
versions git=2.17.1 maven=3.6.3
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
+0 🆗 reexec 1m 36s Docker mode activated.
-0 ⚠️ yetus 0m 3s Unprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --whitespace-eol-ignore-list --whitespace-tabs-ignore-list --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 🆗 mvndep 0m 22s Maven dependency ordering for branch
+1 💚 mvninstall 5m 41s master passed
+1 💚 compile 3m 42s master passed
+1 💚 shadedjars 8m 15s branch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 2m 19s master passed
_ Patch Compile Tests _
+0 🆗 mvndep 0m 17s Maven dependency ordering for patch
+1 💚 mvninstall 5m 36s the patch passed
+1 💚 compile 3m 25s the patch passed
+1 💚 javac 3m 25s the patch passed
+1 💚 shadedjars 8m 4s patch has no errors when building our shaded downstream artifacts.
+1 💚 javadoc 2m 25s the patch passed
_ Other Tests _
+1 💚 unit 2m 20s hbase-common in the patch passed.
+1 💚 unit 1m 38s hbase-client in the patch passed.
+1 💚 unit 0m 51s hbase-zookeeper in the patch passed.
-1 ❌ unit 215m 36s hbase-server in the patch failed.
+1 💚 unit 0m 36s hbase-external-blockcache in the patch passed.
265m 22s
Subsystem Report/Notes
Docker ClientAPI=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 Tests javac javadoc unit shadedjars compile
uname Linux 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 tool maven
Personality dev-support/hbase-personality.sh
git revision master / 1726160
Default Java AdoptOpenJDK-11.0.6+10
unit https://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 Results https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/7/testReport/
Max. process+thread count 3140 (vs. ulimit of 30000)
modules C: hbase-common hbase-client hbase-zookeeper hbase-server hbase-external-blockcache U: .
Console output https://ci-hadoop.apache.org/job/HBase/job/HBase-PreCommit-GitHub-PR/job/PR-2669/7/console
versions git=2.17.1 maven=3.6.3
Powered by Apache Yetus 0.12.0 https://yetus.apache.org

This message was automatically generated.

Copy link
Contributor

@Apache9 Apache9 left a comment

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
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
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:master Nov 28, 2020
@apurtell
Copy link
Contributor Author

apurtell commented Dec 4, 2020

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 <[email protected]>
Signed-off-by: Duo Zhang <[email protected]>
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 <[email protected]>
Signed-off-by: Duo Zhang <[email protected]>
Sign up for free to 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