cxf-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ben Pezzei <>
Subject Retry-Mechanism
Date Tue, 03 Jan 2012 13:30:14 GMT

I am trying to use the Retry-Feature (added in 2.4.4).

Client is configured like this:

<bean id="retryStrategy" class="org.apache.cxf.clustering.RetryStrategy">
	<property name="maxNumberOfRetries" value="5"/>	
	<property name="delayBetweenRetries" value="7000"/>

<jaxws:client id="someService"
                <ref bean="retryStrategy"/>

The idea may be an automatic retry if an IOException occurs (timeout,
Connection refused
or similar).

Note, that we don't use any alternate Addresses in the Strategy (we set the
address before invocation):

BindingProvider bp = (BindingProvider) port;

With this Setup (and if we set the address to some inaccessible url)
the retryStrategy is only invoked once
and stops after one iteration:

WARN - AbstractStaticFailoverStrategy.selectAlternateEndpoint(115) |
no alternate targets remain => giving up on failover

Since we need also some Businesslogic within the Retry-Feature (which
per se is not threadsafe), i'd like
to know, if there are other ways of doing this (Perhaps a
retryInterceptor)? If so, a short example may be highly


View raw message