public void process(Exchange exchange) throws Exception {
RestletEndpoint endpoint = (RestletEndpoint)getEndpoint();
String resourceUri = buildUri(endpoint);
Request request = new Request(endpoint.getRestletMethod(), resourceUri);
RestletBinding binding = endpoint.getRestletBinding();
binding.populateRestletRequestFromExchange(request, exchange);
if (LOG.isDebugEnabled()) {
LOG.debug("Client sends a request (method: " + request.getMethod()
+ ", uri: " + resourceUri + ")");
}
Response response = client.handle(request);
binding.populateExchangeFromRestletResponse(exchange, response);