Use InetSocketAddress.getHostString in favour of getHostName (#22785)

Saves a reverse lookup when the address was initialized as an address.
This commit is contained in:
Arnout Engelen 2017-04-25 22:23:36 -07:00 committed by Johan Andrén
parent cfff0b800c
commit 80c7769767
4 changed files with 12 additions and 12 deletions

View file

@ -63,7 +63,7 @@ class StreamTcpDocSpec extends AkkaSpec {
"initial server banner echo server" in {
val localhost = SocketUtil.temporaryServerAddress()
val connections = Tcp().bind(localhost.getHostName, localhost.getPort) // TODO getHostString in Java7
val connections = Tcp().bind(localhost.getHostString, localhost.getPort)
val serverProbe = TestProbe()
import akka.stream.scaladsl.Framing