Skip to content

Commit

Permalink
[pinpoint-apm#11050] Fix potential NPE
Browse files Browse the repository at this point in the history
  • Loading branch information
emeroad committed Jun 7, 2024
1 parent 1c91445 commit d7f4e7b
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,9 @@ private void bind(List<ServerGroupRequest> serverGroupRequest) {
CompletableFuture<ServerGroupList> future = pair.future();
try {
ServerGroupList serverGroupList = future.getNow(null);
if (serverGroupList == null) {
serverGroupList = serverGroupListFactory.createEmptyNodeInstanceList();
}
node.setServerGroupList(serverGroupList);
} catch (Throwable th) {
logger.warn("Failed to get server info for node {}", node);
Expand Down

0 comments on commit d7f4e7b

Please sign in to comment.