You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cxf.apache.org by Ayush Gupta <ay...@inquisant.com> on 2008/03/14 00:48:52 UTC

Using CXF's Failover Feature

I'm trying to use the failover feature. The documentation for this seems
thin; it is mentioned at http://cwiki.apache.org/CXF20DOC/featureslist.html
and javadocd at
http://incubator.apache.org/cxf/javadoc/latest/org/apache/cxf/clustering/pac
kage-summary.html

 

I understand that I need to enable the failover feature by supplying a
failover strategy and that at runtime, the getAlternateEndpoints is invoked
on my selected FailoverStrategy. Here is how I do it in my client's cxf.xml:

    <bean id="failoverStrategy"
class="org.apache.cxf.clustering.SequentialStrategy"/>

    <cxf:bus>

        <cxf:features>

            <bean id="cluster"
class="org.apache.cxf.clustering.FailoverFeature">

                <property name="strategy" ref="failoverStrategy"/>

            </bean>

            <cxf:logging/>

        </cxf:features>

    </cxf:bus>

 

It is not clear to me how and where I need to supply the alternate endpoints
and if there is anything else I need to do for enabling CXF to look at those
alternate endpoints if invocations on my webservice fail. Has anyone here
used CXF's failover?

 

-ayush


Re: Using CXF's Failover Feature

Posted by Daniel Kulp <dk...@apache.org>.
See:
http://www.nabble.com/Re:-Replica-aware-client-p15469607.html

Dan


On Thursday 13 March 2008, Ayush Gupta wrote:
> I'm trying to use the failover feature. The documentation for this
> seems thin; it is mentioned at
> http://cwiki.apache.org/CXF20DOC/featureslist.html and javadocd at
> http://incubator.apache.org/cxf/javadoc/latest/org/apache/cxf/clusteri
>ng/pac kage-summary.html
>
>
>
> I understand that I need to enable the failover feature by supplying a
> failover strategy and that at runtime, the getAlternateEndpoints is
> invoked on my selected FailoverStrategy. Here is how I do it in my
> client's cxf.xml:
>
>     <bean id="failoverStrategy"
> class="org.apache.cxf.clustering.SequentialStrategy"/>
>
>     <cxf:bus>
>
>         <cxf:features>
>
>             <bean id="cluster"
> class="org.apache.cxf.clustering.FailoverFeature">
>
>                 <property name="strategy" ref="failoverStrategy"/>
>
>             </bean>
>
>             <cxf:logging/>
>
>         </cxf:features>
>
>     </cxf:bus>
>
>
>
> It is not clear to me how and where I need to supply the alternate
> endpoints and if there is anything else I need to do for enabling CXF
> to look at those alternate endpoints if invocations on my webservice
> fail. Has anyone here used CXF's failover?
>
>
>
> -ayush



-- 
J. Daniel Kulp
Principal Engineer, IONA
dkulp@apache.org
http://www.dankulp.com/blog