cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Noman ali abbasi (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (CXF-5298) Session is not maintaining
Date Wed, 25 Sep 2013 04:41:02 GMT

     [ https://issues.apache.org/jira/browse/CXF-5298?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Noman ali abbasi updated CXF-5298:
----------------------------------

    Description: 
i m always getting new session id on each request, i m using apache cxf 2.7.5 version, i have
also tried various solutions like,

Map<String, Object> properties = new HashMap<String, Object>();
		properties.put("thread.local.request.context", Boolean.TRUE);
		properties.put("org.apache.cxf.message.Message.MAINTAIN_SESSION",Boolean.TRUE);
		
factory = new JaxWsProxyFactoryBean();
factory.getInInterceptors().add(new LoggingInInterceptor());
factory.getOutInterceptors().add(new LoggingOutInterceptor());
factory.setServiceClass(MarsWebService.class);        		factory.setAddress("http://localhost:8080/HelloWorld/ws/HWebService?wsdl");

but no luck, i have also bind an user with session id and set web service client at session
level like

HTTP Session Listner
if(webServiceClient.get(httpSession.getId()) == null){
Client client = new Client();
httpSession.setAttribute(httpSession.getId(), client);
}

Struts1 action
HttpSession httpSession = request.getSession();
Client client = (Client) httpSession.getAttribute(httpSession.getId());

  was:
i m always getting new session id on each request, i m using apache cxf 2.7.5 version, i have
also tried various solutions like,

Map<String, Object> properties = new HashMap<String, Object>();
		properties.put("thread.local.request.context", Boolean.TRUE);
		properties.put("org.apache.cxf.message.Message.MAINTAIN_SESSION",Boolean.TRUE);
		
factory = new JaxWsProxyFactoryBean();
factory.getInInterceptors().add(new LoggingInInterceptor());
factory.getOutInterceptors().add(new LoggingOutInterceptor());
factory.setServiceClass(MarsWebService.class);        		factory.setAddress("http://localhost:8080/HelloWorld/ws/HWebService?wsdl");

but no luck, i have also bind an user with session id and set web service client at session
level like
#################### HTTP Session Listner ####################
if(webServiceClient.get(httpSession.getId()) == null){
Client client = new Client();
webServiceClient.put(httpSession.getId(), client);				           httpSession.setAttribute(httpSession.getId(),
client);
}

#################### Struts1 action ####################
HttpSession httpSession = request.getSession();
Client client = (Client) httpSession.getAttribute(httpSession.getId());

    
> Session is not maintaining 
> ---------------------------
>
>                 Key: CXF-5298
>                 URL: https://issues.apache.org/jira/browse/CXF-5298
>             Project: CXF
>          Issue Type: Bug
>    Affects Versions: 2.7.5
>            Reporter: Noman ali abbasi
>
> i m always getting new session id on each request, i m using apache cxf 2.7.5 version,
i have also tried various solutions like,
> Map<String, Object> properties = new HashMap<String, Object>();
> 		properties.put("thread.local.request.context", Boolean.TRUE);
> 		properties.put("org.apache.cxf.message.Message.MAINTAIN_SESSION",Boolean.TRUE);
> 		
> factory = new JaxWsProxyFactoryBean();
> factory.getInInterceptors().add(new LoggingInInterceptor());
> factory.getOutInterceptors().add(new LoggingOutInterceptor());
> factory.setServiceClass(MarsWebService.class);        		factory.setAddress("http://localhost:8080/HelloWorld/ws/HWebService?wsdl");
> but no luck, i have also bind an user with session id and set web service client at session
level like
> HTTP Session Listner
> if(webServiceClient.get(httpSession.getId()) == null){
> Client client = new Client();
> httpSession.setAttribute(httpSession.getId(), client);
> }
> Struts1 action
> HttpSession httpSession = request.getSession();
> Client client = (Client) httpSession.getAttribute(httpSession.getId());

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message