Use java.net.URI in RestTemplate.