From d21bbf4688e367665babd5036c7d2a9b8bb7c854 Mon Sep 17 00:00:00 2001 From: huqingfeng <1397649957@qq.com> Date: Wed, 10 Jun 2020 17:42:17 +0800 Subject: [PATCH] a power of two size for hashmap --- .../java/com/alibaba/nacos/client/naming/net/NamingProxy.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/src/main/java/com/alibaba/nacos/client/naming/net/NamingProxy.java b/client/src/main/java/com/alibaba/nacos/client/naming/net/NamingProxy.java index 73554285d..47e1f0850 100644 --- a/client/src/main/java/com/alibaba/nacos/client/naming/net/NamingProxy.java +++ b/client/src/main/java/com/alibaba/nacos/client/naming/net/NamingProxy.java @@ -197,7 +197,7 @@ public class NamingProxy { NAMING_LOGGER.info("[REGISTER-SERVICE] {} registering service {} with instance: {}", namespaceId, serviceName, instance); - final Map params = new HashMap(9); + final Map params = new HashMap(16); params.put(CommonParams.NAMESPACE_ID, namespaceId); params.put(CommonParams.SERVICE_NAME, serviceName); params.put(CommonParams.GROUP_NAME, groupName);