You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@skywalking.apache.org by GitBox <gi...@apache.org> on 2020/05/25 07:11:43 UTC

[GitHub] [skywalking] wu-sheng commented on a change in pull request #4817: Fix too many mang ipv4 records reported by the agent when deployed in container.

wu-sheng commented on a change in pull request #4817:
URL: https://github.com/apache/skywalking/pull/4817#discussion_r429767145



##########
File path: apm-sniffer/apm-agent-core/src/main/java/org/apache/skywalking/apm/agent/core/os/OSUtil.java
##########
@@ -116,6 +116,9 @@ public static int getProcessNo() {
         }
         List<String> allIPV4 = getAllIPV4();
         if (allIPV4.size() > 0) {
+            if (allIPV4.size() >= ipv4Size) {
+                allIPV4.subList(0, ipv4Size);

Review comment:
       From my reading of the `ArrayList#subList`, the input parameter would not be changed, the new list is the return list. Could you check locally?




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org