int ret;
while ((ret = in.read(buf, 0, 4096)) != -1) {
data.write(buf, 0, ret);
}
HTTPBindingContext bindingContext = new HTTPBindingContext();
bindingContext.setHttpRequest(request);
bindingContext.setHttpResponse(response);
// Dispatch the service interaction to the service invoker
Message requestMessage = messageFactory.createMessage();
requestMessage.setBindingContext(bindingContext);
requestMessage.setBody(new Object[]{data});