setMsgContextProperties(request, response, service, msgContext);
ServiceContext serviceContext = msgContext.getServiceContext();
serviceContext.setProperty(ServiceContext.SERVICE_OBJECT, this.endpointInstance);
InvocationResponse processed = null;
try {
processed = RESTUtil.processURLRequest(msgContext,
response.getOutputStream(),
contentType);
} finally {
// de-associate JAX-WS MessageContext with the thread
// (association happens in POJOEndpointLifecycleManager.createService() call)
POJOWebServiceContext.clear();
}
if (!processed.equals(InvocationResponse.CONTINUE)) {
response.setStatusCode(HttpURLConnection.HTTP_OK);
String s = HTTPTransportReceiver.getServicesHTML(configurationContext);
PrintWriter pw = new PrintWriter(response.getOutputStream());
pw.write(s);
pw.flush();