This is definitely not a common scenario, at least not when using RM. I
don't know of any easy way to support RM across a cluster of servers,
since you'd need to fully coordinate all actions across the servers
(even to the point of making sure that messages are delivered in correct
sequence to the application endpoint, assuming you're using in-order
delivery). This could be done, as you suggested, by using the
persistence store, but would require considerable change to the current
implementation to make it work since the current persistence code
assumes there's only one reader and writer.
In order to run with the existing code you need to make sure each client
always connects to the same server (which obviously limits the
usefulness of your load balancing). I'd think the same limitation would
apply to other statefull protocols such as WS-SecureConversation, too.
- Dennis
Dennis M. Sosnoski
Java Web Services Consulting <http://www.sosnoski.com/consult.html>
CXF and Web Services Security Training
<http://www.sosnoski.com/training.html>
Web Services Jump-Start <http://www.sosnoski.com/jumpstart.html>
On 11/10/2014 11:28 PM, kupkaj wrote:
I'm building an asynchronous webservice that will be consumed using ws-rm
protocol.
Clients will be addressing hardware loadbalancer, which will route request
to 2..n integration servers.
I ran into a problem regarding ws-rm sequences: let's say client needs to
create new sequence. LB routes this request to server A. Later on, client is
re-using this newly created sequence, but this time LB routes request to
server B. This request fails, because sequence created on server A (sequence
owner) is not known on server B.
I guess this is pretty common scenario... Can anybody help me with solution?
I was able to configure ws-rm persistence store, but it is only partial
mitigation to this problem (all created sequences are restored after server
restart, but are not synchronized between servers during runtime).
Basically I need to replicate ID of all created sequences between server
instances behind LB (once sequence is created/terminated, all servers need
to be notified and need to update their list of sequences in memory).
Could this be achieved using custom interceptor?
CXF itself supports load-balancing, but I haven't took closer look at it.
Would it solve this problem?
Thank you for any help.
--
View this message in context:
http://cxf.547215.n5.nabble.com/WS-RM-sequences-behind-load-balancer-tp5750901.html
Sent from the cxf-user mailing list archive at Nabble.com.