public static String fetchRemoteAddress(final Connection connection) {
        if (connection == null) {
            return "";
        }
        final List<String> remoteAddressInfos = new ArrayList<>();
        for (final Principal principal : connection.getPrincipals()) {
            if (principal instanceof org.jboss.remoting3.security.InetAddressPrincipal) {
                final InetAddress inetAddress = ((org.jboss.remoting3.security.InetAddressPrincipal) principal).getInetAddress();
                initializeRemoteAddressInfo(remoteAddressInfos, inetAddress);
                break;
            }
        }
        return remoteAddressInfos.toString();
    }
Fetch remote address.

@param connection the connection
@return the string
agent-module/plugins/jboss/src/main/java/com/navercorp/pinpoint/plugin/jboss/util/JbossUtility.java