public static QueueServiceStub getQueueServiceClient(ServletConfig config, HttpSession session,
HttpServletRequest request)
throws AxisFault {
String backendServerURL = CarbonUIUtil.getServerURL(config.getServletContext(), session);
backendServerURL = backendServerURL + "QueueService";
QueueServiceStub stub = new QueueServiceStub(backendServerURL);
String cookie = (String) session.getAttribute(ServerConstants.ADMIN_SERVICE_COOKIE);
if (cookie != null) {
Options option = stub._getServiceClient().getOptions();
option.setManageSession(true);
option.setProperty(org.apache.axis2.transport.http.HTTPConstants.COOKIE_STRING, cookie);
}
return stub;
}