Java 8 の inetaddress に関する問題について質問を投稿しました: InetAddress java 8 is not gets the hostname
ただし、System.getenv("HOSTNAME")代わりに使用することで簡単な解決策を見つけましたInetAddress.getLocalHost().getHostName()...
を使用してホスト名を取得することの違いを知りたい:
InetAddress.getLocalHost().getHostName();
また
System.getenv("HOSTNAME")
影響はありますか?どちらが良いですか?