You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cxf.apache.org by tho huynh ngoc <ng...@gmail.com> on 2015/04/16 01:46:06 UTC
Session timeout between JAX-WS Server and Client
Hi,
I have a JAX-WS Service using UDP as follows
JaxWsServerFactoryBean factory = new JaxWsServerFactoryBean();
factory.setAddress("udp://192.168.56.1:9393/print");
factory.setServiceClass(Service.class);
factory.setServiceBean(this);
factory.getInInterceptors().add(new LoggingInInterceptor());
factory.getOutInterceptors().add(new LoggingOutInterceptor());
factory.create().start();
And a client:
factory_client = new JaxWsProxyFactoryBean();
factory_client.getInInterceptors().add(new LoggingInInterceptor());
factory_client.getOutInterceptors().add(new
LoggingOutInterceptor());
factory_client.setServiceClass(Service.class);
String addrToServer = "udp://192.168.56.1:9393/print";
factory_client.setAddress(addrToServer);
Map<String, Object> props_client = new HashMap<String,Object>();
props_client.put("cxf.synchronous.timeout", new Integer(60000));
factory_client.setProperties(props_client);
service_client = (Service) factory_client.create();
How to configure a session timeout to maintain the connection between them?
Please help me,
Thank you in advance,
Best regards,
Tho,