this will NPE if rawHostname wasn't set