Skip to content

Commit 789775b

Browse files
wavesZhkun-song
authored andcommitted
Change CopyOnWriteArrayList to regular list in DubboProtocol (#4056)
1 parent 0b380e3 commit 789775b

File tree

1 file changed

+1
-2
lines changed
  • dubbo-rpc/dubbo-rpc-dubbo/src/main/java/org/apache/dubbo/rpc/protocol/dubbo

1 file changed

+1
-2
lines changed

dubbo-rpc/dubbo-rpc-dubbo/src/main/java/org/apache/dubbo/rpc/protocol/dubbo/DubboProtocol.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,6 @@
5858
import java.util.concurrent.CompletableFuture;
5959
import java.util.concurrent.ConcurrentHashMap;
6060
import java.util.concurrent.ConcurrentMap;
61-
import java.util.concurrent.CopyOnWriteArrayList;
6261

6362
import static org.apache.dubbo.common.constants.CommonConstants.GROUP_KEY;
6463
import static org.apache.dubbo.common.constants.CommonConstants.INTERFACE_KEY;
@@ -544,7 +543,7 @@ private void batchClientRefIncr(List<ReferenceCountExchangeClient> referenceCoun
544543
* @return
545544
*/
546545
private List<ReferenceCountExchangeClient> buildReferenceCountExchangeClientList(URL url, int connectNum) {
547-
List<ReferenceCountExchangeClient> clients = new CopyOnWriteArrayList<>();
546+
List<ReferenceCountExchangeClient> clients = new ArrayList<>();
548547

549548
for (int i = 0; i < connectNum; i++) {
550549
clients.add(buildReferenceCountExchangeClient(url));

0 commit comments

Comments
 (0)