Перейти к содержимому
Mineforgian

Fast IP Ping

Yeet the laggy reversed DNS lookup for literal IP server addresses

Загрузки
18.7M
Подписчики
1K
Обновлён
16 апреля 2026 г.
Лицензия
LGPL-3.0-only

Опубликован 19 августа 2023 г.

Исходный кодСообщить об ошибке

pinging

Yeet the laggy reversed DNS lookup for literal IP server addresses

Extracted from the yeetServerIpReversedDnsLookup option in TweakerMore Mod

What & Why & How

For servers whose addresses are represented solely by a literal IP, e.g. 192.168.2.10:25565, disable reverse DNS lookups in the corresponding InetAddress object

Many non-loopback IPs lack associated domain names, which makes reverse lookups time-consuming

// java.net.InetAddress#getHostName(boolean)
String getHostName(boolean check) {
    if (holder().getHostName() == null) {  // It will be null if InetAddress.getByName() received a literal IP
        holder().hostName = InetAddress.getHostFromNameService(this, check);  // <-- takes forever
    }
    return holder().getHostName();
}

This option sets the domain of those servers directly to their IP, bypassing the reverse DNS check

This results in a 1s ~ 5s reduction in time for servers with literal IP address. Affects the following environments:

  • Pinging the server in the server list screen
  • Connecting to the server

Environment

  • Client-side only
  • Fabric / Forge / NeoForge mod loader. No extra requirement is needed

Ченджлог

v1.0.11-mc1.21.10-neoforgeРелиз1.21.9, 1.21.10 · 16 апреля 2026 г.
  • mc26.1 forge-like: fix init log

Build Information

v1.0.11-mc1.21.11-neoforgeРелиз1.21.11 · 16 апреля 2026 г.
  • mc26.1 forge-like: fix init log

Build Information

v1.0.11-mc1.21.5-neoforgeРелиз1.21.5 · 16 апреля 2026 г.
  • mc26.1 forge-like: fix init log

Build Information

v1.0.11-mc1.21.8-neoforgeРелиз1.21.6, 1.21.7, 1.21.8 · 16 апреля 2026 г.
  • mc26.1 forge-like: fix init log

Build Information

v1.0.11-mc1.21.4-neoforgeРелиз1.21.4 · 16 апреля 2026 г.
  • mc26.1 forge-like: fix init log

Build Information

v1.0.11-mc1.21.3-neoforgeРелиз1.21.2, 1.21.3 · 16 апреля 2026 г.
  • mc26.1 forge-like: fix init log

Build Information

v1.0.11-mc1.21.1-neoforgeРелиз1.21, 1.21.1 · 16 апреля 2026 г.
  • mc26.1 forge-like: fix init log

Build Information

v1.0.11-mc1.20.4-forgeРелиз1.20.2, 1.20.3, 1.20.4 · 16 апреля 2026 г.
  • mc26.1 forge-like: fix init log

Build Information

Комментарии

Загружаем…