Most (all?) workstations aren't going to have a DNS entry anyway. The IP is about as good as you can get.
Uhmm.
Behind firewall/NAT/router, you have public IP address which usually has PTR (reverse DNS) record set by your ISP.
Each and every computer behind that NAT will share that IP and thus that domain PTR record.
Test yours here: https://myip.dk
Now, if you're deploying your application in an enterprise (i.e. Intranet), there is also big chance that local clients are in a domain, and will also have PTR's. For instance, in our development company we have such thing. So my computer will always have stamster.company
static DNS.
So @jeiel needs to clarify which scenario he's looking at. In any case, even if there is no reverse DNS hostname for a certain IP, gethostbyaddr
will simply return IP as a hostname.
And top conclusion would be DO NOT run reverse DNS of any kind on a production system.
Use message broker instead.